Skip to content

Commit 8340444

Browse files
committed
tweak vary k
1 parent 3dac857 commit 8340444

3 files changed

Lines changed: 9 additions & 9 deletions

File tree

python/src/images/vary_k.pdf

430 Bytes
Binary file not shown.

python/src/vary_k.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
#
22
# AUTO-GENERATED FILE. DO NOT EDIT
3-
# CodeBuff 1.4.19 'Sat Jun 18 16:15:58 PDT 2016'
3+
# CodeBuff 1.4.19 'Sun Jun 19 13:53:54 PDT 2016'
44
#
55
import matplotlib.pyplot as plt
66

7-
java_st=[0.07020408, 0.060402684, 0.053435113, 0.05352798, 0.05352798, 0.053435113, 0.053435113, 0.05352798, 0.053435113, 0.053435113, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113]
8-
java8_st=[0.074074075, 0.057747833, 0.05319149, 0.05233853, 0.048482955, 0.047131147, 0.050808314, 0.047115386, 0.047115386, 0.048245613, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235]
9-
antlr=[0.19766825, 0.1815235, 0.20090996, 0.16949153, 0.16718563, 0.16694611, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16742516, 0.16906475, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153]
10-
sqlite=[0.11827957, 0.11478599, 0.104304634, 0.10646388, 0.11026616, 0.102564104, 0.10547945, 0.10593607, 0.11085451, 0.102833636, 0.102564104, 0.1098546, 0.1098546, 0.11111111, 0.11111111, 0.11111111, 0.108545035, 0.108545035, 0.108545035, 0.108545035, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10248902]
11-
tsql=[0.11255411, 0.099585064, 0.09504132, 0.08627451, 0.093835615, 0.09090909, 0.09090909, 0.09090909, 0.09150327, 0.09150327, 0.09150327, 0.08847185, 0.08847185, 0.08847185, 0.08847185, 0.09670782, 0.09174312, 0.09885932, 0.09756097, 0.08579089, 0.08579089, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.09090909]
7+
java_st=[0.07020408, 0.060402684, 0.053435113, 0.05352798, 0.05352798, 0.053435113, 0.053435113, 0.05352798, 0.053435113, 0.053435113, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.05303761, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113, 0.053435113]
8+
java8_st=[0.074074075, 0.057747833, 0.05319149, 0.05233853, 0.048482955, 0.047131147, 0.050808314, 0.047115386, 0.047115386, 0.048245613, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235, 0.049844235]
9+
antlr=[0.19766825, 0.1815235, 0.20090996, 0.16949153, 0.16718563, 0.16694611, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16718563, 0.16742516, 0.16906475, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153, 0.16949153]
10+
sqlite=[0.11827957, 0.11478599, 0.104304634, 0.10646388, 0.11026616, 0.102564104, 0.10547945, 0.10593607, 0.11085451, 0.102833636, 0.102564104, 0.1098546, 0.1098546, 0.11111111, 0.11111111, 0.11111111, 0.108545035, 0.108545035, 0.108545035, 0.108545035, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10569106, 0.10330579, 0.10330579, 0.10330579, 0.106038295, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579, 0.10330579]
11+
tsql=[0.11255411, 0.099585064, 0.09504132, 0.08627451, 0.093835615, 0.09090909, 0.09090909, 0.09090909, 0.09150327, 0.09150327, 0.09150327, 0.08847185, 0.08847185, 0.08847185, 0.08847185, 0.09670782, 0.09174312, 0.09885932, 0.09756097, 0.08579089, 0.08579089, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.08579089, 0.09852941, 0.09885932, 0.09558824, 0.09558824, 0.09558824, 0.09885932, 0.09885932, 0.09090909, 0.09090909, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.09885932, 0.08579089, 0.08579089, 0.08579089, 0.08579089, 0.08579089, 0.08579089, 0.08579089, 0.08579089, 0.08579089]
1212

13-
ks = [1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 131]
13+
ks = [1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, 99]
1414
fig = plt.figure()
1515
ax = plt.subplot(111)
1616
ax.plot(ks, java_st, label="java_st", marker='s', color='g')

src/org/antlr/codebuff/validation/TestK.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ public static void main(String[] args) throws Exception {
4848
TSQL_CLEAN_DESCR,
4949
};
5050

51-
int MAX_K = 51; // should be odd
52-
int OUTLIER_K = 131;
51+
int MAX_K = 98; // should be odd
52+
int OUTLIER_K = 99;
5353
List<Integer> ks = new ArrayList<>();
5454
for (int i = 1; i<=MAX_K; i+=2) {
5555
ks.add(i);

0 commit comments

Comments
 (0)