Download presentation
Presentation is loading. Please wait.
Published byJeffry Ross Modified over 8 years ago
1
Exploiting Input Features for Controlling Tunable Approximate Programs Sherry Zhou Department of electronic engineering Tsinghua University
2
Outline Introduction Input features for GEM and SGD Experiments on applying features to error model Experiments on applying new features to cost model Conclusion and future work
3
Overview of Control Method
4
Control Problem Formulation Given: – a tunable program, – a set of possible inputs I, and – a probability function p such that for any i ∈ I, p(i) is the probability of getting input i For input i ∈ I, error bound ε > 0 and probability bound 0 ≤ π ≤ 1, find k 1, k 2 such that – Objective: minimize f c (i, k 1, k 2 ) – Subject to: ≥ π Feasible Region – Set of (k 1, k 2 ) satisfying : ≥ π 4
5
Error and Cost Model Error model is used to determine whether or not a knob setting is in the feasible region – Currently is input-agnostic Cost model uses input features, knob settings to predict running time – Currently is input-specific, simple features
6
Problem We Focused On Find and exploit computational cheap Input features: – Make error model input-awareness to improve its accuracy – Improve cost model accuracy
7
Two Benchmarks We Focused On GEM error model SGD error model GEM cost modelSGD cost model features
8
INPUT FEATURES
9
Features for GEM Input are social networks Simple features: – Number of nodes – Number of edges – Number of cluster
10
Features for GEM Sophisticated features but easy to compute: – Leadership – Sub-graph Edge Ratio – Degree Distribution
11
Feature: Leadership Small groups are usually created by one individual who then recruits others L = ∑ (d max − d i ) / ((n − 2)(n − 1)) Normalize: ∑((n-1)-1)= (n − 2)(n − 1)
12
Feature: Sub-Graph Edge Ratio Composed by those high-degree nodes Ratio of number of edges in the original to those in the sub-graph
13
Feature: Degree Distribution Take the scaled distribution as a vector and use K-means to get the vectors into groups
14
Other Features Explored High Computational Cost Hop-count – defined as the minimal number of distinct links that forms a path connecting the two nodes Clustering Coefficient – defined as the ratio of the number of links y connecting the di neighbors of i over the maximum possible ½y* di(di − 1) Bonding – Measures triadic closure in a graph
15
Features in SGD Inputs: training instances for SVM classifier Feature: ratio of number of instances to instance dimension: When ratio < 1 – Easier to find a solution When ratio > 1 – Harder to find a solution
16
APPLY FEATURES TO ERROR MODEL 16
17
Apply Features to Error Model Directly add features as nodes in Bayes network – High inference cost when number of features are high knob1 knob2 error knob1 knob2 error Feature 1 Feature 2
18
GEM: Add Features to Bayes Network Add features: – Number of nodes – Number of edges
19
GEM: Add Features to Bayes Network Add features: – leadership
20
GEM: Add Features to Bayes Network Add features: – Sub-graph edge ratio
21
GEM: Apply Features to Error Model Use features to classify inputs and in each class, learn a different model. INPUT CLASSIFIER ERROR MODEL 1 ERROR MODEL n
22
Results: Only Use Number of Nodes The performance become worse.
23
Feature: Sub-Graph Edges
24
Features: Leadership The performance has been slightly improved
25
Clustering Inputs Based on Knob Errors
26
Future Work Features: – What kinds of features are more useful to improve error model? Principle? – Will a combination of features be better?
27
COST MODEL 27
28
Result: add leadership feature to cost model in GEM Leadership Number of nodes Number of edges Number of nodes Number of edges Feature in cost model:
29
Result: add leadership feature to cost model in GEM leadership Number of nodes Number of edges Number of nodes Number of edges Feature in cost model:
30
SGD
31
Future Work The relationship between runtime and cache miss? Build an analytic model of runtime prediction Analyze the difference between analytic model with m5-tree model Provide some guidance to m5 learning algoirhtm
32
Conclusion Explored several features to improve error and cost models Experiments showed the error and cost model are improved
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.