A Stochastic Graph Grammar Algorithm for Interactive Search

Download Report

Transcript A Stochastic Graph Grammar Algorithm for Interactive Search

A Stochastic Graph Grammar
Algorithm for Interactive Search
Rahul Rai
Assistant Professor
Department of Mechanical
Engineering
California State University
at Fresno
Fresno, California 93740
[email protected]
Tolga Kurtoglu
Research Scientist
Mission Critical
Technologies
Intelligent Systems Division
NASA Ames Research
Center
Moffett Field, California
94035
[email protected]
Matthew I. Campbell
Associate Professor
Automated Design Laboratory
Department of Mechanical
Engineering
University of Texas at Austin
Austin, Texas 78712-0292
[email protected]
Introduction
• generative grammars is a powerful approach to represent
different topologies, configurations or shapes within a
single search space
– approaches the representational capacity of human designers
that create and compare wildly different solutions during the
conceptual design phase
– We are interested in how grammars can be used to interactively
guide human designers or even automatically find promising
concepts
• grammars merely define a space or tree of solutions
– not a means to search this space
– search trees -- intractably large set of solutions
– Need some way to evaluate concepts
• target specific areas of the tree that best meet the designer’s
expectations.
• Evaluation completely left to humans
– Difficult on concepts when no dimensions are provided
Approach
1. present a sample of solutions to the designer
2. Get feedback
3. use that information to find better solutions in the search
tree
• seeks solutions to maximize the designer’s preference
• reflecting the user input onto the generative grammar rules
–
–
–
–
which rule
combination of rules
ordering of rules
time to execute a particular rule
…leads to the best design
Seed Rules for necktie knot grammar
In order to begin any tie knot a triangular basis has to be
created. This beginning move creates three regions L C R (Left,
Center, Right). This gives rise to seed rules. One can begin in
two way Li and Lo (i denotes in plane and o denotes out plane).
Continuing rules for tie knot
• One can continue from the seed rule by implementing one of
the six rules shown here
• There are two restriction on continuing rules.
• First, the i and o has to alternate
• Second, next step cannot have same basis, i.e., if previous step
is L then next step has to be either C or R.
Terminating rules for tie knots
• A tie knot can only terminate in one of the
possible two ways shown above.
• T denotes (termination and no more rules can
be applied)
18 graph grammar rules for tie knots
•Based on initiation, continuing, and terminating aspects of tie knot, only 18
graph grammar rules can be deduced for the tie knot problem. The rules code
in graphsynth are as follows:
Rule 1
LHS
Rule 2
Rule 3
LHS
Lo
Lo
RHS
RHS
LoRi
LoCi
LHS
Ri
RHS
RiCo
Rule 4
LHS
Ri
RHS
RiLo
Rule 5
LHS
Co
RHS CoLi
Rule 6
LHS
Co
RHS
CoRi
Rule 11
Rule 7
LHS
Li
RHS
LiCo
Rule 12
Rule 8
LHS
Li
RHS
LiRo
Rule 13
Rule 9
LHS
Ro
RHS
RoCi
Rule 14
Rule 10
LHS
Ro
RHS
RoLi
Rule 15
Rule 11
LHS
Ci
RHS
Rule 12
LHS
Ci
CiRo
Rule 16
RHS CiLo
Rule 17 (Initiation )
Rule 13
LHS
Null
RHS
Li
Rule 18 (Initiation )
Rule 14
LHS Null
Rule 15
LHS Co
RHS Lo
Rule 19 (Termination )
RHS CoT
4
A green number denote that rule selected for application among applicable rules
Vertex where to apply a rule in the LHS of a step
Four in hand knot
Step 1
Seed graph (Null)
Li
Applicable Rules 13, 14
Step 2
Li
Li
Ro
Applicable Rules 7, 8
Step 3
Li
Ro
Li
Ro
Li
Applicable Rules 9, 10
Step 4
Li
Ro
Li
Li
Ro
Li
Co
Applicable Rules 7, 8
Step 5
Li
Ro
Li
Co
Li
Applicable Rules 5, 6, 15
Ro
Li
Co
T
4
A green number denote that rule selected for application among applicable rules
Vertex where to apply a rule in the LHS of a step
Step 1
Seed graph (Null)
Cross knot 1
Li
Applicable Rules 13, 14
Step 2
Li
Li
Ro
Applicable Rules 7,8
Step 3
Li
Ro
Li
Ro
Ci
Applicable Rules 9, 10
Step 4
Li
Ro
Ci
Applicable Rules 11,12
Li
Ro
Ci
Ro
Step 5
Li
Ro
Ci
Ro
Li
Ro
Ci
Ro
Applicable Rules 9,10
Li
Cross knot 2
Step 6
Li
Ro
Ci
Li
Ro
Ro
Ci
Ro
Co
Li
Applicable Rules 7,8
Li
Step 7
Li
Ro
Ci
Ro
Li
Ro
Ci
Ro
Applicable Rules 5, 6, 15
Co
Li
T
Co
Li
4
A green number denote that rule selected for application among applicable rules
Vertex where to apply a rule in the LHS of a step
Step 1
Seed graph (Null)
Windsor 1
Li
Applicable Rules 13, 14
Step 2 and 3
Step 2
Li
Applicable Rules 7,8
Li
Co
Step 3
Li
Co
Li
Co
Li
Applicable Rules 5, 6, 15
Step 4
Li
Co
Li
Li
Co
Li
Ro
Li
Co
Li
Applicable Rules 7,8
Step 5
Li
Co
Li
Ro
Applicable Rules 9,10
Ro
Ci
Windsor 2
Step 6
Li
Co
Li
Ro
Ci
Li
Applicable Rules 11, 12
Co
Li
Ro
Ci
Ro
Step 7
Li
Co
Li
Ro
Li
Ci
Ro
Co
Li
Applicable Rules 9, 10
Ro
Ci
Ro
Li
Step 8
Li
Co
Li
Li
Ro
Co
Ci
Li
Ro
Ro
Li
Ci
Applicable Rules 7,8
Ro
Li
Co
Step 9
Li
Co
Li
Li
Co
Ro
Li
Ci
Ro
Ro
Ci
Li
Ro
Co
Li
Applicable Rules 5,6,15
Co
T
4
A green number denote that rule selected for application among applicable rules
Vertex where to apply a rule in the LHS of a step
Small knot
Step 1
Seed graph (Null)
Lo
Applicable Rules 13, 14
Step 2
Lo
Lo
Ri
Lo
Ri
Applicable Rules 1, 2
Step 3
Lo
Ri
Co
Applicable Rules 3, 4
Step 4
Lo
Ri
Lo
Co
Applicable Rules 5 ,4, 15
Ri
Co
T
T31
T24
T32
T37
T48
Co
Co
Ri
Co
Ri
Li
T25
Li
Co
T20
Ri
Li
Co
Co
Ri
Li
Li
Lo
Co
Lo
Ro
Ro
Ro
Co
Ri
Co
Lo
Ri
Ro
Ro
Ci
Ri
Ci
Co
Li
T1
Ro
Ro
Li
Li
Co
Ri
T19
Co
Ro
Li
Ci
Lo
Lo
Ri
Co
Ri
Li
Lo
TT4
Ri
Ri
Li
Co
T16
Lo
Co
Ci
Ri
Ri
Ro
Ro
Lo
Co
Li
Ci
Co
T47
T8
Ri
Co
Ri
Ro
Lo
Ro
Ro
Ri
Co
Co
Co
T52
T15
T49
T50
T34
T57
T36
T58
T44
T55
Co
Co
T41
T14
Ri
Co
Co
Co
Li
Li
T22
Co
Li
Ri
Lo
Co
Li
Ri
Co
Lo
Li
Lo
Ci
Co
T6
T11
Ro
Co
T45
Co
Lo
Li
Lo
Co
T42
Ri
T26
Ri
Li
Co
Ro
Ci
Lo
Ri
T38
Li
Co
Ro
Ci
Co
T17
Ci
Lo
Li
Ro
Ri
Lo
Ci
T2
Ro
Co
T51
Ri
Lo
Ri
T54
Co
Lo
Lo
T5
Co
Li
Ci
Co
Ri
Co
T23
Ri
Ro
Ci
Lo
T12
Lo
Lo
Ri
Ri
Co
Ri
Ci
Ri
T39
Co
Lo
Ro
Co
Lo
Li
Ro
Co
T13
Co
Li
T35
Li
Lo
Li
Co
Ri
Ro
Ci
Co
Co
Li
Lo
T40
Co
Li
Li
Ro
Ri
Ri
Ci
Ro
Li
T53
Ro
Lo
Co
Li
Lo
T3
Co
T10
Co
T7
T27
T33
Co
T9
Co
T29
(85
solutions)
T43
Co
Ri
Maximum
of Nine
Steps
T46
Co
Co
T30
T28
title: “A Stochastic Graph Grammar
Algorithm for Interactive Search”
• the tree is never explicitly represented
– large and difficult to visualize
– may easily contain more states than the computer can store
– 1010 =9.3 TB if each state in only one kilobyte
• However, the number of rules that lead to these solutions is often a
small and manageable size
– grammar rules represent heuristics or constraints provided by experts
in the particular design domain
• grammar rules make definitive changes to a particular concept and
their use is often clearly discernible within the final candidate
solution
– makes sense to gather statistics on the rules used to navigate the
search tree
• In the necktie grammar, rules define shape and size of the knot.
Stochastic Process
• any given state in the tree, a set of options is
determined
rule7
rule1
rule3
rule6
rule
Database
Fitness
Popularity
(higher is (lower is
better)
better)
1
1.2
5
2
-0.4
3
3
0.8
2
4
2.5
2
5
-1.6
7
6
N/A
0
7
-1.3
6
rule3
rule1
rule6
Fit.
Pop.
f1
1
1.2
5
1
3
0.8
2
6
7
N/A
-1.3
0
6
(0.8-[-1.3])
/(1.2-[-1.3]) =
0.84
0.5
0
f2
(5-6)/(06) = 0.167
(2-6)/(06) = 0.667
1
0
rule
rule7
Fitness
Popularity
(higher is (lower is
better)
better)
1
1.2
5
2
-0.4
3
3
0.8
2
4
2.5
2
5
-1.6
7
6
N/A
0
7
-1.3
6
Ftot=B*f1 + (1- B)*f2 +
0.005
0.2
0.5
0.339 0.589
0.9
0.922
0.691 0.759
0.739
0.905 0.755
0.005 0.005
0.555
0.005
B named for
G.E.P. Box. First
to coin the
phrase
“exploration vs.
exploitation”
B = [0 1]
Fit.
Pop.
f1
1
1.2
5
1
3
0.8
2
6
7
N/A
-1.3
0
6
(0.8-[-1.3])
/(1.2-[-1.3]) =
0.84
0.5
0
f2
(5-6)/(06) = 0.167
(2-6)/(06) = 0.667
1
0
Ftot=B*f1 + (1- B)*f2 +
0.005
0.2
0.5
0.339 0.589
0.9
0.922
0.691 0.759
0.739
0.905 0.755
0.005 0.005
0.555
0.005
rule1
rule7
rule3
rule6
Q
0
0.5
0.8
1
P
1/500
1
2
500
0.589
0.251
0.279
0.232
0.000
0.759
0.251
0.360
0.386
0.910
0.755
0.251
0.358
0.382
0.090
0.005
0.248
0.002
2E-05
0.000
Recreate the Cross-Knot
Distance Metric from Cross-Knot
14
12
10
8
6
4
2
0
1
201
401
601
801
1001
1201
1401
1601
1801
2001
2201
2401
2601
2801
3001
3201
3401
3601
3801
4001
4201
4401
4601
4801
5001
5201
5401
• Go all the way to 15th
level of tree (5461
candidates)
• Calculate difference
from cross-knot
120%
30%
100%
25%
80%
20%
60%
15%
PDF
CDF
40%
10%
20%
5%
0%
0%
1
2
3
4
5
6
7
8
9 10 11 12 13 14
Results
# OF
DESIGNS
TO
PRESEN
# OF
T
ITERATIONS Average St.Dev
B**
Q
0.5
0.5
3
10
4.33
0.58
Q
ave.
0.5
0.5
4
5
4.33
1.15
0.5
5.11
3.14
0.5
0.5
5
3
6.67
5.69
0.8
7.78
0.5
0.8
3
10
7.67
4.04
1
7.33
0.5
0.8
4
5
9.00
5.29
0.5
0.8
5
3
6.67
6.11
0.5
1
3
10
3.67
3.51
0.5
1
4
5
7.67
4.73
0.5
1
5
3
10.67
2.31
StDev experiments
ave.
StDev
"3-10"
5.22
3.27
4.63
"4-5"
7.00
4.15
4.39
"5-3"
8.00
4.77
After reviewing 30 out of 5461 solutions, we find a solution in 98 percentile.