Skip to content
View DeepPerf's full-sized avatar

Block or report DeepPerf

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Maximum 250 characters. Please don't include any personal information such as legal names or email addresses. Markdown supported. This note will be visible to only you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
DeepPerf/README.md

DeepPerf

Many software systems provide users with a set of configuration options and different configurations may lead to different runtime performance of the system. It is necessary to understand the performance of a system under a certain configuration, before the system is actually configured and deployed. This helps users make rational decisions in configurations and reduce performance testing cost. As the combination of configurations could be exponential, it is difficult to exhaustively deploy and measure system performance under all possible configurations. Recently, several learning methods have been proposed to build a performance prediction model based on performance data collected from a small sample of configurations, and then use the model to predict system performance with a new configuration. DeepPerf is an end-to-end deep learning based solution that can train a software performance prediction model from a limited number of samples and predict the performance value of software system under a new configuration. DeepPerf consists of two main stages:

  • Stage 1: Tune the hyperparameters of the neural network
  • Stage 2: Utilize the hyperparameters in Stage 1 to train the neural network with the samples and predict the performance value of software system under a new configuration.

Citing DeepPerf

If you find our code useful, please cite our paper:

@inproceedings{Ha2019DeepPerf, author ={Huong Ha and Hongyu Zhang}, title ={DeepPerf: performance prediction for configurable software with deep sparse neural network}, booktitle ={Proceedings of the 41st International Conference on Software Engineering,{ICSE} 2019, Montreal, QC, Canada, May 25-31, 2019}, pages ={1095--1106}, publisher ={{IEEE} /{ACM}}, year ={2019} } 

Prerequisites

  • Python 3.6.x
  • Tensorflow (tested with tensorflow 1.10.0, 1.8.0)

Installation

DeepPerf can be directly executed through source code

  1. Download and install Python 3.6.x here.

  2. Install Tensorflow

    $ pip install tensorflow==1.10.0

  3. Clone DeepPerf

    $ clone https://github.com/DeepPerf/DeepPerf.git

Data

DeepPerf has been evaluated on 11 real-world configurable software systems:

  • Apache
  • LLVM
  • x264
  • BDBC
  • BDBJ
  • SQL
  • Dune
  • hipacc
  • hsmgp
  • javagc
  • sac

Six of these systems have only binary configuration options, the other five systems have both binary and numeric configuration options. The data is store in the DeepPerf\Data directory. These software systems were measured and published online by the SPLConqueror team. More information of these systems and how they were measured can be found in here.

Usage

To run DeepPerf, users need to specify the name of the software system they wish to evaluate and then run the script AutoDeepPerf.py. There are 11 software systems that users can evaluate: Apache, LLVM, x264, BDBC, BDBJ, SQL, Dune, hipacc, hsmgp, javagc, sac. The script will then evaluate DeepPerf on the chosen software system with the same experiment setup presented in our paper. Specifically, for binary software systems, DeepPerf will run with five different sample sizes: n, 2n, 3n, 4n, 5n with n being the number of options, and 30 experiments for each sample size. For binary-numeric software systems, DeepPerf will run with the sample sizes specified in Table IV of our paper, and 30 experiments for each sample size. For example, if users want to evaluate DeepPerf with the system LLVM, the command line to run DeepPerf will be:

$ python AutoDeepPerf.py LLVM

When finishing each sample size, the script will output a .csv file that shows the mean prediction error and the margin (95% confidence interval) of that sample size over the 30 experiments. These results will be same/similar as the results we report in Table III and IV of our paper.

Alternatively, users can customize the sample size and/or the number of experiments for each sample size by using the optional arguments -ss and -ne. For example, to set the sample size = 20 and the number of experiments = 10, the corresponding command line is:

$ python AutoDeepPerf.py LLVM -ss 20 -ne 10

Setting none or one option will result in the other option(s) running with the default setting. The default setting of the number of experiments is 30. The default setting of the sample size is: (a) the five different sample sizes: n, 2n, 3n, 4n, 5n, with n being the number of configuration options, when the evaluated system is a binary system OR (b) the four sample sizes specified in Table IV of our paper when the evaluated system is a binary-numeric system.

NOTE: The time cost of tuning hyperparameters and training the final neural network for each experiment ranges from 2-20 minutes depends on the software system, the sample size and the user's CPU. Typically, the time cost will be smaller when the software systems has smaller number of configurations or when the sample size is small. Therefore, please be aware that for each sample size, the time cost of evaluating 30 experiments ranges from 1 hour to 10 hours.

Experimental Results

To evaluate the prediction accuracy, we use the mean relative error (MRE), which is computed as,

where V is the testing dataset, predicted_c is the predicted performance value of configuration c generated using the model, actual_c is the actual performance value of configuration c. In the two tables below, Mean is the mean of the MREs seen in 30 experiments and Margin is the margin of the 95% confidence interval of the MREs in the 30 experiments. The results are obtained when evaluating DeepPerf on a Windows 7 computer with Intel Xeon CPU E5-1650 3.2GHz 16GB RAM.

Prediction accuracy for software systems with binary options

Subject SystemSample SizeDECARTDeepPerf
MeanMarginMeanMargin
ApachenNANA17.871.85
2n15.832.89 10.24 1.15
3n11.031.468.250.75
4n9.491.006.970.39
5n7.840.286.290.44
x264n17.713.8710.432.28
2n9.311.303.610.54
3n6.370.832.13 0.31
4n4.260.471.490.38
5n2.940.520.870.11
BDBJn10.044.677.254.21
2n2.230.162.070.32
3n2.030.161.730.12
4n1.720.091.670.12
5n1.670.091.610.09
LLVMn6.000.345.090.80
2n4.660.473.870.48
3n3.960.392.540.15
4n3.540.422.270.16
5n2.840.331.990.15
BDBCn151.090.70133.654.33
2n43.826.7216.772.25
3n31.922.7313.13.39
4n6.931.396.951.11
5n5.021.695.821.33
SQLn4.870.225.040.32
2n4.670.174.630.13
3n4.360.094.480.08
4n4.210.14.400.14
5n4.110.084.270.13

Prediction accuracy for software systems with binary-numeric options

Subject SystemSample SizeSPLConquerorDeepPerf
Sampling HeuristicMeanSampling HeuristicMeanMargin
Dune49OW RD20.1RD15.730.90
78PW RD22.1RD13.670.82
240OW PBD(49, 7)10.6RD8.190.34
375OW PBD(125, 5)18.8RD7.200.17
hipacc261OW RD14.2RD9.390.37
528OW PBD(125, 5)13.8RD6.380.44
736OW PBD(49, 7)13.9RD5.060.35
1281PW RD13.9RD3.750.26
hsmgp77OW RD4.5RD6.760.87
173PW RD2.8RD3.600.2
384OW PBD(49, 7)2.2RD2.530.13
480OW PBD(125, 5)1.7RD2.240.11
javagc423OW PBD(49, 7)37.4RD24.762.42
534OW RD31.3RD23.274.00
855OW PBD(125, 5)21.9RD21.837.07
2571OW PBD(49, 7)28.2RD17.327.89
sac2060OW RD21.1RD15.831.25
2295OW PBD(125, 5)20.3RD17.955.63
2499OW PBD(49, 7)16RD17.132.22
3261PW RD30.7RD15.402.05

Popular repositories Loading

  1. DeepPerf DeepPerfPublic

    DeepPerf is an end-to-end deep learning based solution that can train a software performance prediction model from a limited number of samples and predict the performance value of a new configuration.

    Python 15 12

  2. deeplearning-models deeplearning-modelsPublic

    Forked from rasbt/deeplearning-models

    A collection of various deep learning architectures, models, and tips

    Jupyter Notebook

  3. nl2bash nl2bashPublic

    Forked from TellinaTool/nl2bash

    Generating bash command from natural language https://arxiv.org/abs/1802.08979

    NewLisp