├── AutoTAMP_plotting.ipynb ├── Example_results ├── cook │ ├── myfile0.txt │ ├── myfile1.txt │ └── myfile2.txt ├── rover │ ├── myfile0.txt │ ├── myfile1.txt │ └── myfile2.txt └── wall │ ├── myfile0.txt │ ├── myfile1.txt │ ├── myfile2.txt │ └── myfile3.txt ├── Illustraton of three methods.png ├── LICENSE ├── PWLPlan.py ├── README.md ├── autotamp_single_agent.py ├── env_and_optimize_single_agent.py ├── experiment_result ├── HouseWorld │ └── instr_dir │ │ ├── myfile_sent1.txt │ │ ├── myfile_sent10.txt │ │ ├── myfile_sent2.txt │ │ ├── myfile_sent3.txt │ │ ├── myfile_sent4.txt │ │ ├── myfile_sent5.txt │ │ ├── myfile_sent6.txt │ │ ├── myfile_sent7.txt │ │ ├── myfile_sent8.txt │ │ └── myfile_sent9.txt ├── chip │ ├── gpt-4-with-syntactic-semantic │ │ └── sent0 │ │ │ ├── myfile0.txt │ │ │ ├── myfile_time_consume0.txt │ │ │ └── stl_output.txt │ ├── gpt4-with-syntactic │ │ └── sent0 │ │ │ ├── myfile0.txt │ │ │ ├── myfile1.txt │ │ │ ├── myfile4.txt │ │ │ └── stl_output.txt │ └── instr_dir │ │ └── myfile_sent1.txt └── myfile.txt ├── llm_task_plan.py ├── openai_func.py └── vis.py /Example_results/cook/myfile0.txt: -------------------------------------------------------------------------------- 1 | 1.500000 2.500000 0.000000 2 | 1.500000 1.103970 0.279206 3 | 1.500000 0.790000 0.342000 4 | 1.470000 0.790000 0.352000 5 | 1.470000 2.350000 0.664000 6 | 1.470000 3.470000 0.888000 7 | 0.790000 3.470000 1.024000 8 | 0.790000 3.530000 1.036000 9 | 3.470000 3.530000 1.572000 10 | 3.470000 4.210000 1.708000 11 | 3.470000 4.210000 1.718000 12 | -------------------------------------------------------------------------------- /Example_results/cook/myfile1.txt: -------------------------------------------------------------------------------- 1 | 2.500000 1.500000 0.000000 2 | 2.500000 0.790000 0.269206 3 | 2.470000 0.790000 0.674000 4 | 2.530000 1.420000 0.812000 5 | 1.730000 1.470000 0.982000 6 | 0.790000 1.470000 1.170000 7 | 0.790000 1.530000 1.182000 8 | 2.180000 1.530000 1.460000 9 | 3.470000 1.580000 1.728000 10 | 3.470000 4.210000 2.254000 11 | 3.520000 4.210000 2.264000 12 | -------------------------------------------------------------------------------- /Example_results/cook/myfile2.txt: -------------------------------------------------------------------------------- 1 | 3.500000 3.500000 0.000000 2 | 3.500000 3.450000 0.010000 3 | 3.530000 3.430000 0.020000 4 | 3.530000 3.480000 0.030000 5 | 3.530000 3.530000 0.040000 6 | 3.530000 3.530000 0.050000 7 | 3.480000 3.530000 0.060000 8 | 3.430000 3.530000 0.070000 9 | 3.380000 3.530000 0.080000 10 | 3.380000 3.530000 0.090000 11 | 3.380000 3.530000 0.100000 12 | -------------------------------------------------------------------------------- /Example_results/rover/myfile0.txt: -------------------------------------------------------------------------------- 1 | 4.500000 6.500000 0.000000 2 | 4.080000 6.500000 0.084000 3 | 4.080000 8.920000 0.568000 4 | 2.090000 8.920000 0.966000 5 | 2.030000 8.920000 0.978000 6 | 2.030000 6.080000 1.546000 7 | 2.090000 6.080000 1.558000 8 | 2.441909 6.080000 1.628382 9 | 3.553970 6.080000 1.850794 10 | 4.110000 6.080000 1.962000 11 | 4.110000 6.080000 1.972000 12 | -------------------------------------------------------------------------------- /Example_results/rover/myfile1.txt: -------------------------------------------------------------------------------- 1 | 4.500000 4.500000 0.000000 2 | 4.080000 4.500000 0.084000 3 | 4.080000 2.080000 0.568000 4 | 2.090000 2.080000 0.966000 5 | 2.030000 2.080000 0.978000 6 | 2.030000 4.870000 1.536000 7 | 2.030000 4.920000 1.546000 8 | 2.090000 4.920000 1.558000 9 | 2.997939 4.920000 1.739588 10 | 4.110000 4.920000 1.962000 11 | 4.110000 4.920000 1.972000 12 | -------------------------------------------------------------------------------- /Example_results/rover/myfile2.txt: -------------------------------------------------------------------------------- 1 | 7.500000 6.500000 0.000000 2 | 7.920000 6.500000 0.084000 3 | 7.920000 8.920000 0.568000 4 | 9.920000 8.920000 0.968000 5 | 9.970000 8.920000 0.978000 6 | 9.970000 2.090000 2.344000 7 | 9.970000 2.090000 2.354000 8 | 9.970000 4.920000 2.920000 9 | 9.910000 4.920000 2.932000 10 | 7.890000 4.920000 3.336000 11 | 7.890000 4.920000 3.346000 12 | -------------------------------------------------------------------------------- /Example_results/wall/myfile0.txt: -------------------------------------------------------------------------------- 1 | 2.000000 0.500000 0.000000 2 | 2.999086 1.049086 0.968562 3 | 4.430000 1.049086 1.445533 4 | 4.430000 2.480000 1.922504 5 | 2.424315 2.480000 2.591066 6 | 2.390000 3.110000 2.812504 7 | 2.390000 3.110000 2.822504 8 | -------------------------------------------------------------------------------- /Example_results/wall/myfile1.txt: -------------------------------------------------------------------------------- 1 | 4.000000 0.500000 0.000000 2 | 4.000000 0.925228 0.141743 3 | 4.430000 1.474315 0.468105 4 | 4.430000 1.920457 0.616819 5 | 4.430000 2.915685 0.948562 6 | 4.390000 3.110000 1.026667 7 | 4.390000 3.110000 1.036667 8 | -------------------------------------------------------------------------------- /Example_results/wall/myfile2.txt: -------------------------------------------------------------------------------- 1 | 6.000000 0.500000 0.000000 2 | 4.580457 0.500000 0.626819 3 | 4.570000 1.484772 0.958562 4 | 4.570000 2.480000 1.290305 5 | 5.005685 2.480000 1.435533 6 | 5.610000 3.110000 1.846971 7 | 5.640000 3.110000 1.856971 8 | -------------------------------------------------------------------------------- /Example_results/wall/myfile3.txt: -------------------------------------------------------------------------------- 1 | 8.000000 0.500000 0.000000 2 | 6.575685 1.520000 1.932504 3 | 4.570000 1.520000 2.601066 4 | 4.570000 2.480000 2.921066 5 | 7.610000 2.480000 3.934400 6 | 7.610000 3.110000 4.144400 7 | 7.610000 3.110000 4.154400 8 | -------------------------------------------------------------------------------- /Illustraton of three methods.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yongchao98/AutoTAMP/71e5000964dd234a4b08fbaf5e7703b85732bb8b/Illustraton of three methods.png -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2024 Yongchao Chen 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /PWLPlan.py: -------------------------------------------------------------------------------- 1 | from gurobipy import * 2 | from math import * 3 | import numpy as np 4 | import time 5 | 6 | M = 1e3 7 | # a large M causes numerical issues and make the model infeasible to Gurobi 8 | T_MIN_SEP = 1e-2 9 | # see comments in GreaterThanZero 10 | IntFeasTol = 1e-1 * T_MIN_SEP / M 11 | 12 | def setM(v): 13 | global M, IntFeasTol 14 | M = v 15 | IntFeasTol = 1e-1 * T_MIN_SEP / M 16 | 17 | EPS = 1e-2 18 | 19 | def _sub(x1, x2): 20 | return [x1[i] - x2[i] for i in range(len(x1))] 21 | 22 | def _add(x1, x2): 23 | return [x1[i] + x2[i] for i in range(len(x1))] 24 | 25 | def L1Norm(model, x): 26 | xvar = model.addVars(len(x), lb=-GRB.INFINITY) 27 | abs_x = model.addVars(len(x)) 28 | model.update() 29 | xvar = [xvar[i] for i in range(len(xvar))] 30 | abs_x = [abs_x[i] for i in range(len(abs_x))] 31 | for i in range(len(x)): 32 | model.addConstr(xvar[i] == x[i]) 33 | model.addConstr(abs_x[i] == abs_(xvar[i])) 34 | return sum(abs_x) 35 | 36 | class Conjunction(object): 37 | # conjunction node 38 | def __init__(self, deps = []): 39 | super(Conjunction, self).__init__() 40 | self.deps = deps 41 | self.constraints = [] 42 | 43 | class Disjunction(object): 44 | # disjunction node 45 | def __init__(self, deps = []): 46 | super(Disjunction, self).__init__() 47 | self.deps = deps 48 | self.constraints = [] 49 | 50 | def noIntersection(a, b, c, d): 51 | # z = 1 iff. [a, b] and [c, d] has no intersection 52 | # b < c or d < a 53 | return Disjunction([c-b-EPS, a-d-EPS]) 54 | 55 | def hasIntersection(a, b, c, d): 56 | # z = 1 iff. [a, b] and [c, d] has no intersection 57 | # b >= c and d >= a 58 | return Conjunction([b-c, d-a]) 59 | 60 | def always(i, a, b, zphis, PWL): 61 | t_i = PWL[i][1] 62 | t_i_1 = PWL[i+1][1] 63 | conjunctions = [] 64 | for j in range(len(PWL)-1): 65 | t_j = PWL[j][1] 66 | t_j_1 = PWL[j+1][1] 67 | conjunctions.append(Disjunction([noIntersection(t_j, t_j_1, t_i + a, t_i_1 + b), zphis[j]])) 68 | return Conjunction(conjunctions) 69 | 70 | def eventually(i, a, b, zphis, PWL): 71 | t_i = PWL[i][1] 72 | t_i_1 = PWL[i+1][1] 73 | z_intervalWidth = b-a-(t_i_1-t_i)-EPS 74 | disjunctions = [] 75 | for j in range(len(PWL)-1): 76 | t_j = PWL[j][1] 77 | t_j_1 = PWL[j+1][1] 78 | disjunctions.append(Conjunction([hasIntersection(t_j, t_j_1, t_i_1 + a, t_i + b), zphis[j]])) 79 | return Conjunction([z_intervalWidth, Disjunction(disjunctions)]) 80 | 81 | def bounded_eventually(i, a, b, zphis, PWL, tmax): 82 | t_i = PWL[i][1] 83 | t_i_1 = PWL[i+1][1] 84 | z_intervalWidth = b-a-(t_i_1-t_i)-EPS 85 | disjunctions = [] 86 | for j in range(len(PWL)-1): 87 | t_j = PWL[j][1] 88 | t_j_1 = PWL[j+1][1] 89 | disjunctions.append(Conjunction([hasIntersection(t_j, t_j_1, t_i_1 + a, t_i + b), zphis[j]])) 90 | return Disjunction([Conjunction([z_intervalWidth, Disjunction(disjunctions)]), t_i+b-tmax-EPS]) 91 | 92 | def until(i, a, b, zphi1s, zphi2s, PWL): 93 | t_i = PWL[i][1] 94 | t_i_1 = PWL[i+1][1] 95 | z_intervalWidth = b-a-(t_i_1-t_i)-EPS 96 | disjunctions = [] 97 | for j in range(len(PWL)-1): 98 | t_j = PWL[j][1] 99 | t_j_1 = PWL[j+1][1] 100 | conjunctions = [hasIntersection(t_j, t_j_1, t_i_1 + a, t_i + b), zphi2s[j]] 101 | for l in range(j+1): 102 | t_l = PWL[l][1] 103 | t_l_1 = PWL[l+1][1] 104 | conjunctions.append(Disjunction([noIntersection(t_l, t_l_1, t_i, t_i_1 + b), zphi1s[l]])) 105 | disjunctions.append(Conjunction(conjunctions)) 106 | return Conjunction([z_intervalWidth, Disjunction(disjunctions)]) 107 | 108 | def release(i, a, b, zphi1s, zphi2s, PWL): 109 | t_i = PWL[i][1] 110 | t_i_1 = PWL[i+1][1] 111 | conjunctions = [] 112 | for j in range(len(PWL)-1): 113 | t_j = PWL[j][1] 114 | t_j_1 = PWL[j+1][1] 115 | disjunctions = [noIntersection(t_j, t_j_1, t_i_1 + a, t_i + b), zphi2s[j]] 116 | for l in range(j): 117 | t_l = PWL[l][1] 118 | t_l_1 = PWL[l+1][1] 119 | disjunctions.append(Conjunction([hasIntersection(t_l, t_l_1, t_i_1, t_i_1 + b), zphi1s[l]])) 120 | conjunctions.append(Disjunction(disjunctions)) 121 | return Conjunction(conjunctions) 122 | 123 | def mu(i, PWL, bloat_factor, A, b): 124 | bloat_factor = np.max([0, bloat_factor]) 125 | # this segment is fully contained in Ax<=b (shrinked) 126 | b = b.reshape(-1) 127 | num_edges = len(b) 128 | conjunctions = [] 129 | for e in range(num_edges): 130 | a = A[e,:] 131 | for j in [i, i+1]: 132 | x = PWL[j][0] 133 | conjunctions.append(b[e] - np.linalg.norm(a) * bloat_factor - sum([a[k]*x[k] for k in range(len(x))]) - EPS) 134 | return Conjunction(conjunctions) 135 | 136 | def negmu(i, PWL, bloat_factor, A, b): 137 | # this segment is outside Ax<=b (bloated) 138 | b = b.reshape(-1) 139 | num_edges = len(b) 140 | disjunctions = [] 141 | for e in range(num_edges): 142 | a = A[e,:] 143 | conjunctions = [] 144 | for j in [i, i+1]: 145 | x = PWL[j][0] 146 | conjunctions.append(sum([a[k]*x[k] for k in range(len(x))]) - (b[e] + np.linalg.norm(a) * bloat_factor) - EPS) 147 | disjunctions.append(Conjunction(conjunctions)) 148 | return Disjunction(disjunctions) 149 | 150 | def add_space_constraints(model, xlist, limits, bloat=0.): 151 | xlim, ylim = limits 152 | for x in xlist: 153 | model.addConstr(x[0] >= (xlim[0] + bloat)) 154 | model.addConstr(x[1] >= (ylim[0] + bloat)) 155 | model.addConstr(x[0] <= (xlim[1] - bloat)) 156 | model.addConstr(x[1] <= (ylim[1] - bloat)) 157 | 158 | return None 159 | 160 | def add_time_constraints(model, PWL, tmax=None): 161 | if tmax is not None: 162 | model.addConstr(PWL[-1][1] <= tmax - T_MIN_SEP) 163 | 164 | for i in range(len(PWL)-1): 165 | x1, t1 = PWL[i] 166 | x2, t2 = PWL[i+1] 167 | model.addConstr(t2 - t1 >= T_MIN_SEP) 168 | 169 | def add_velocity_constraints(model, PWL, vmax=3): 170 | for i in range(len(PWL)-1): 171 | x1, t1 = PWL[i] 172 | x2, t2 = PWL[i+1] 173 | # squared_dist = sum([(x1[j]-x2[j])*(x1[j]-x2[j]) for j in range(len(x1))]) 174 | # model.addConstr(squared_dist <= (vmax**2) * (t2 - t1) * (t2 - t1)) 175 | L1_dist = L1Norm(model, _sub(x1,x2)) 176 | model.addConstr(L1_dist <= vmax * (t2 - t1)) 177 | 178 | def disjoint_segments(model, seg1, seg2, bloat): 179 | assert(len(seg1) == 2) 180 | assert(len(seg2) == 2) 181 | # assuming that bloat is the error bound in two norm for one agent 182 | return 0.5 * L1Norm(model, _sub(_add(seg1[0], seg1[1]), _add(seg2[0], seg2[1]))) - 0.5 * (L1Norm(model, _sub(seg1[0], seg1[1])) + L1Norm(model, _sub(seg2[0], seg2[1]))) - 2*bloat*np.sqrt(len(seg1[0])) - EPS 183 | 184 | def add_mutual_clearance_constraints(model, PWLs, bloat): 185 | for i in range(len(PWLs)): 186 | for j in range(i+1, len(PWLs)): 187 | PWL1 = PWLs[i] 188 | PWL2 = PWLs[j] 189 | for k in range(len(PWL1)-1): 190 | for l in range(len(PWL2)-1): 191 | x11, t11 = PWL1[k] 192 | x12, t12 = PWL1[k+1] 193 | x21, t21 = PWL2[l] 194 | x22, t22 = PWL2[l+1] 195 | z_noIntersection = noIntersection(t11, t12, t21, t22) 196 | z_disjoint_segments = disjoint_segments(model, [x11, x12], [x21, x22], bloat) 197 | z = Disjunction([z_noIntersection, z_disjoint_segments]) 198 | add_CDTree_Constraints(model, z) 199 | 200 | class Node(object): 201 | """docstring for Node""" 202 | def __init__(self, op, deps = [], zs = [], info = []): 203 | super(Node, self).__init__() 204 | self.op = op 205 | self.deps = deps 206 | self.zs = zs 207 | self.info = info 208 | 209 | def clearSpecTree(spec): 210 | for dep in spec.deps: 211 | clearSpecTree(dep) 212 | spec.zs = [] 213 | 214 | def handleSpecTree(spec, PWL, bloat_factor, size): 215 | for dep in spec.deps: 216 | handleSpecTree(dep, PWL, bloat_factor, size) 217 | if len(spec.zs) == len(PWL)-1: 218 | return 219 | elif len(spec.zs) > 0: 220 | raise ValueError('incomplete zs') 221 | if spec.op == 'mu': 222 | spec.zs = [mu(i, PWL, 0.1, spec.info['A'], spec.info['b']) for i in range(len(PWL)-1)] 223 | elif spec.op == 'negmu': 224 | spec.zs = [negmu(i, PWL, bloat_factor + size, spec.info['A'], spec.info['b']) for i in range(len(PWL)-1)] 225 | elif spec.op == 'and': 226 | spec.zs = [Conjunction([dep.zs[i] for dep in spec.deps]) for i in range(len(PWL)-1)] 227 | elif spec.op == 'or': 228 | spec.zs = [Disjunction([dep.zs[i] for dep in spec.deps]) for i in range(len(PWL)-1)] 229 | elif spec.op == 'U': 230 | spec.zs = [until(i, spec.info['int'][0], spec.info['int'][1], spec.deps[0].zs, spec.deps[1].zs, PWL) for i in range(len(PWL)-1)] 231 | elif spec.op == 'F': 232 | spec.zs = [eventually(i, spec.info['int'][0], spec.info['int'][1], spec.deps[0].zs, PWL) for i in range(len(PWL)-1)] 233 | elif spec.op == 'BF': 234 | spec.zs = [bounded_eventually(i, spec.info['int'][0], spec.info['int'][1], spec.deps[0].zs, PWL, spec.info['tmax']) for i in range(len(PWL)-1)] 235 | elif spec.op == 'A': 236 | spec.zs = [always(i, spec.info['int'][0], spec.info['int'][1], spec.deps[0].zs, PWL) for i in range(len(PWL)-1)] 237 | else: 238 | raise ValueError('wrong op code') 239 | 240 | def gen_CDTree_constraints(model, root): 241 | if not hasattr(root, 'deps'): 242 | return [root,] 243 | else: 244 | if len(root.constraints)>0: 245 | # TODO: more check here 246 | return root.constraints 247 | dep_constraints = [] 248 | for dep in root.deps: 249 | dep_constraints.append(gen_CDTree_constraints(model, dep)) 250 | zs = [] 251 | for dep_con in dep_constraints: 252 | if isinstance(root, Disjunction): 253 | z = model.addVar(vtype=GRB.BINARY) 254 | zs.append(z) 255 | dep_con = [con + M * (1 - z) for con in dep_con] 256 | root.constraints += dep_con 257 | if len(zs)>0: 258 | root.constraints.append(sum(zs)-1) 259 | model.update() 260 | return root.constraints 261 | 262 | def add_CDTree_Constraints(model, root): 263 | constrs = gen_CDTree_constraints(model, root) 264 | for con in constrs: 265 | model.addConstr(con >= 0) 266 | 267 | 268 | # Define the callback function 269 | def termination_callback(model, where): 270 | if where == GRB.Callback.MIPSOL: 271 | # Get the current solution's objective value 272 | current_obj = model.cbGet(GRB.Callback.MIPSOL_OBJ) 273 | 274 | # Get the best known objective value so far 275 | best_obj = model.cbGet(GRB.Callback.MIPSOL_OBJBST) 276 | 277 | # Set a tolerance for the objective value change 278 | tolerance = 1e-2 279 | 280 | # Set a maximum number of iterations without significant change 281 | max_no_change = 5 282 | 283 | # Get the current number of iterations 284 | # = model.cbGet(GRB.Callback.MIPNODE_NODCNT) 285 | 286 | # Check if the change in objective value is below the tolerance 287 | if abs(current_obj - best_obj) < tolerance: 288 | model._no_change_count += 1 289 | else: 290 | model._no_change_count = 0 291 | 292 | # Terminate optimization if there is no significant change for the set number of iterations 293 | if model._no_change_count >= max_no_change: 294 | model.terminate() 295 | 296 | def plan(x0s, specs, bloat, limits=None, num_segs=None, tasks=None, vmax=3., MIPGap=1e-4, max_segs=None, tmax=None, hard_goals=None, size=0.11*4/2): 297 | if num_segs is None: 298 | min_segs = 1 299 | assert max_segs is not None 300 | else: 301 | min_segs = num_segs 302 | max_segs = num_segs 303 | 304 | for num_segs in range(min_segs, max_segs+1): 305 | for spec in specs: 306 | clearSpecTree(spec) 307 | 308 | if tasks: 309 | for task in tasks: 310 | for t in task: 311 | clearSpecTree(t) 312 | 313 | print('----------------------------') 314 | print('num_segs', num_segs) 315 | 316 | PWLs = [] 317 | m = Model("xref") 318 | m.Params.TimeLimit = 2000.0 319 | # m.setParam(GRB.Param.OutputFlag, 0) 320 | m.setParam(GRB.Param.IntFeasTol, IntFeasTol) 321 | m.setParam(GRB.Param.MIPGap, MIPGap) 322 | # m.setParam(GRB.Param.NonConvex, 2) 323 | # m.getEnv().set(GRB_IntParam_OutputFlag, 0) 324 | 325 | for idx_a in range(len(x0s)): 326 | x0 = x0s[idx_a] 327 | x0 = np.array(x0).reshape(-1).tolist() 328 | spec = specs[idx_a] 329 | 330 | dims = len(x0) 331 | 332 | PWL = [] 333 | for i in range(num_segs+1): 334 | PWL.append([m.addVars(dims, lb=-GRB.INFINITY), m.addVar()]) 335 | PWLs.append(PWL) 336 | m.update() 337 | 338 | # the initial constriant 339 | m.addConstrs(PWL[0][0][i] == x0[i] for i in range(dims)) 340 | m.addConstr(PWL[0][1] == 0) 341 | 342 | if hard_goals is not None: 343 | goal = hard_goals[idx_a] 344 | m.addConstrs(PWL[-1][0][i] == goal[i] for i in range(dims)) 345 | 346 | if limits is not None: 347 | add_space_constraints(m, [P[0] for P in PWL], limits) 348 | 349 | add_velocity_constraints(m, PWL, vmax=vmax) 350 | add_time_constraints(m, PWL, tmax) 351 | 352 | handleSpecTree(spec, PWL, bloat, size) 353 | add_CDTree_Constraints(m, spec.zs[0]) 354 | 355 | if tasks is not None: 356 | for idx_agent in range(len(tasks)): 357 | for idx_task in range(len(tasks[idx_agent])): 358 | handleSpecTree(tasks[idx_agent][idx_task], PWLs[idx_agent], bloat, size) 359 | 360 | conjunctions = [] 361 | for idx_task in range(len(tasks[0])): 362 | disjunctions = [tasks[idx_agent][idx_task].zs[0] for idx_agent in range(len(tasks))] 363 | conjunctions.append(Disjunction(disjunctions)) 364 | z = Conjunction(conjunctions) 365 | add_CDTree_Constraints(m, z) 366 | 367 | add_mutual_clearance_constraints(m, PWLs, bloat) 368 | 369 | # obj = sum([L1Norm(m, _sub(PWL[i][0], PWL[i+1][0])) for PWL in PWLs for i in range(len(PWL)-1)]) 370 | obj = sum([PWL[-1][1] for PWL in PWLs]) 371 | m.setObjective(obj, GRB.MINIMIZE) 372 | 373 | m.write("test.lp") 374 | print('NumBinVars: %d'%m.getAttr('NumBinVars')) 375 | 376 | # Initialize the counter for the number of iterations without significant change 377 | m._no_change_count = 0 378 | try: 379 | start = time.time() 380 | #m.optimize(termination_callback) 381 | m.optimize() 382 | end = time.time() 383 | print('sovling it takes %.3f s'%(end - start)) 384 | PWLs_output = [] 385 | for PWL in PWLs: 386 | PWL_output = [] 387 | for P in PWL: 388 | PWL_output.append([[P[0][i].X for i in range(len(P[0]))], P[1].X]) 389 | PWLs_output.append(PWL_output) 390 | m.dispose() 391 | return PWLs_output 392 | except Exception as e: 393 | m.dispose() 394 | return [None,] 395 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # AutoTAMP ([Website](https://yongchao98.github.io/MIT-REALM-AutoTAMP/), ICRA 2024) 2 | Paper Link: https://arxiv.org/pdf/2306.06531.pdf 3 | 4 |
5 | Main image 6 |
7 | 8 | ## Requirements 9 | Please install the Gurobi optimizer by following the instructions on the official website https://www.gurobi.com/products/gurobi-optimizer/ 10 | You might be eligible for a free academic license https://www.gurobi.com/academia/academic-program-and-licenses/ 11 | 12 | Then install the following Python packages. 13 | ``` 14 | pip install numpy matplotlib pypoman openai re random time copy 15 | ``` 16 | 17 | Then you need to get your OpenAI key from https://beta.openai.com/ 18 | Put that OpenAI key starting 'sk-' into the openai_func.py, line9 19 | 20 | ## Usage 21 | Run the autotamp_single_agent.py to test the AutoTAMP method (with/without checkers). From line7 to line11, set up the parameters for syntactic check, semantic check, domain, your working path dir, and model choice. Then run the script: 22 | 23 | ``` 24 | python autotamp_single_agent.py 25 | ``` 26 | 27 | For testing the Task Planning method, also set up the parameters for domain, your working path dir, and model choice. Then run the script: 28 | 29 | ``` 30 | python llm_task_plan.py 31 | ``` 32 | 33 | The experimental results will appear in the dir experiment_result. 34 | 35 | ## Visualization 36 | We have uploaded the AutoTAMP_plotting.ipynb and Example_results directory to give the visualization examples. During the experiments, myfile{i}.txt will be created to record the position/time waypoints, which are used for visualization when giving the environmental plots. 37 | 38 | ## Cite 39 | 40 | @article{chen2023autotamp, 41 | title={AutoTAMP: Autoregressive Task and Motion Planning with LLMs as Translators and Checkers}, 42 | author={Chen, Yongchao and Arkin, Jacob and Zhang, Yang and Roy, Nicholas and Fan, Chuchu}, 43 | journal={arXiv preprint arXiv:2306.06531}, 44 | year={2023} 45 | } 46 | 47 | ## Recommended Work 48 | 49 | [NL2TL: Transforming Natural Languages to Temporal Logics using Large Language Models](https://arxiv.org/pdf/2305.07766.pdf) 50 | 51 | [Scalable Multi-Robot Collaboration with Large Language Models: Centralized or Decentralized Systems?](https://yongchao98.github.io/MIT-REALM-Multi-Robot/) 52 | -------------------------------------------------------------------------------- /autotamp_single_agent.py: -------------------------------------------------------------------------------- 1 | from env_and_optimize_single_agent import NL2action 2 | from openai_func import * 3 | import random 4 | import os 5 | 6 | # pre-define five parameters 7 | syntactic_correct_loop = True # for syntactic check loop 8 | semantic_correct_loop = True # for semantic check loop 9 | domain = 'chip' # 'HouseWorld' or 'chip' 10 | experiment_result_dir = 'path-to-the-code-directory/experiment_result' # the directory of experiment_result 11 | model_name = 'gpt-4' # 'gpt-3' or 'gpt-4' 12 | 13 | 14 | if domain == 'chip': 15 | for index in range(1): 16 | if syntactic_correct_loop == True and semantic_correct_loop == True: 17 | saving_path_test_case = experiment_result_dir + '/chip/' + model_name + '-with-syntactic-semantic' 18 | elif syntactic_correct_loop == True and semantic_correct_loop == False: 19 | saving_path_test_case = experiment_result_dir + '/chip/' + model_name + '-with-syntactic' 20 | elif syntactic_correct_loop == False and semantic_correct_loop == False: 21 | saving_path_test_case = experiment_result_dir + '/chip/' + model_name + '-without-check' 22 | 23 | if not os.path.exists(experiment_result_dir + '/chip/'): 24 | os.mkdir(experiment_result_dir + '/chip/') 25 | if not os.path.exists(saving_path_test_case): 26 | os.mkdir(saving_path_test_case) 27 | instruction_path = experiment_result_dir + '/chip/instr_dir' 28 | if not os.path.exists(instruction_path): 29 | os.mkdir(instruction_path) 30 | saving_path = saving_path_test_case + '/sent' + str(index) 31 | if not os.path.exists(saving_path): 32 | os.mkdir(saving_path) 33 | with open(instruction_path + '/myfile_sent' + str(index+1) + '.txt', 'r') as file: 34 | input_instruction = file.read().split('\n\n') 35 | #print(len(input_instruction)) 36 | for item in input_instruction: 37 | print(item) 38 | with open(saving_path + '/stl_output.txt', 'a') as f_STL_output: 39 | for i in range(len(input_instruction)): 40 | ### For Chip Challenge 41 | if len(input_instruction[i]) > 5: 42 | print('input_instruction' + str(i) + ': ', input_instruction[i]) 43 | try: 44 | output_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic = NL2action(i, saving_path, input_instruction[i], 45 | start_position=[4.5 + random.uniform(-0.1, 0.1), 2 + random.uniform(-0.1, 0.1)], 46 | end_position=[1.15 + random.uniform(-0.1, 0.1), 1.15 + random.uniform(-0.1, 0.1)], 47 | syntactic_correct_loop=syntactic_correct_loop, 48 | semantic_correct_loop=semantic_correct_loop, 49 | model_name=model_name, # gpt-3 or gpt-4 50 | environment = 'env2', # env1 or env2 or env3 51 | domain = 'chip' 52 | ) 53 | if mark_syntactic == 1: 54 | f_STL_output.write('Syntactic correct' + '\n') 55 | f_STL_output.write(str(i) + '. ' + str(output_stl) + '\n\n') 56 | f_STL_output.write(str(TL_list) + '\n\n') 57 | if mark_syntactic == 0: 58 | f_STL_output.write('Syntactic wrong' + '\n') 59 | f_STL_output.write(str(i) + '. ' + str(output_stl) + '\n\n') 60 | f_STL_output.write(str(TL_list) + '\n\n') 61 | except: 62 | pass 63 | f_STL_output.close() 64 | 65 | elif domain == 'HouseWorld': 66 | ### For HouseWorld 67 | for index in range(10): 68 | instruction_path = experiment_result_dir + '/HouseWorld/instr_dir' 69 | saving_path_test_case = experiment_result_dir + '/HouseWorld/' + model_name + '-with-syntactic-semantic' 70 | if not os.path.exists(saving_path_test_case): 71 | os.mkdir(saving_path_test_case) 72 | 73 | saving_path = saving_path_test_case + '/sent' + str(index) 74 | if not os.path.exists(saving_path): 75 | os.mkdir(saving_path) 76 | 77 | with open(instruction_path + '/myfile_sent' + str(index+1) + '.txt', 'r') as file: 78 | input_instruction = file.read().split('\n\n') 79 | print('Length of different instructions of this kind is: ', len(input_instruction)) 80 | for item in input_instruction: 81 | print(item) 82 | with open(saving_path + '/stl_output.txt', 'a') as f_STL_output: 83 | for i in range(len(input_instruction)): 84 | if len(input_instruction[i]) > 5: 85 | print('input_instruction' + str(i) + ': ', input_instruction[i]) 86 | if index == 8: 87 | try: 88 | output_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic = NL2action(i, saving_path, input_instruction[i], 89 | start_position=[-1.35 + random.uniform(-0.1, 0.1), -1.1 + random.uniform(-0.1, 0.1)], 90 | end_position=[1.15 + random.uniform(-0.1, 0.1), 1.15 + random.uniform(-0.1, 0.1)], 91 | syntactic_correct_loop=syntactic_correct_loop, 92 | semantic_correct_loop=semantic_correct_loop, 93 | model_name=model_name, 94 | domain='HouseWorld' 95 | ) 96 | if mark_syntactic == 1: 97 | f_STL_output.write('Syntactic correct' + '\n') 98 | f_STL_output.write(str(i) + '. ' + str(output_stl) + '\n\n') 99 | f_STL_output.write(str(TL_list) + '\n\n') 100 | if mark_syntactic == 0: 101 | f_STL_output.write('Syntactic wrong' + '\n') 102 | f_STL_output.write(str(i) + '. ' + str(output_stl) + '\n\n') 103 | f_STL_output.write(str(TL_list) + '\n\n') 104 | except: 105 | pass 106 | 107 | try: 108 | output_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic = NL2action(i + 10, saving_path, input_instruction[i], 109 | start_position=[-1.35 + random.uniform(-0.1, 0.1), -1.1 + random.uniform(-0.1, 0.1)], 110 | end_position=[1.15 + random.uniform(-0.1, 0.1), 1.15 + random.uniform(-0.1, 0.1)], 111 | syntactic_correct_loop=syntactic_correct_loop, 112 | semantic_correct_loop=semantic_correct_loop, 113 | model_name=model_name, 114 | domain='HouseWorld' 115 | ) 116 | if mark_syntactic == 1: 117 | f_STL_output.write('Syntactic correct' + '\n') 118 | f_STL_output.write(str(i + 10) + '. ' + str(output_stl) + '\n\n') 119 | f_STL_output.write(str(TL_list) + '\n\n') 120 | if mark_syntactic == 0: 121 | f_STL_output.write('Syntactic wrong' + '\n') 122 | f_STL_output.write(str(i + 10) + '. ' + str(output_stl) + '\n\n') 123 | f_STL_output.write(str(TL_list) + '\n\n') 124 | except: 125 | pass 126 | 127 | else: 128 | try: 129 | output_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic = NL2action(i, saving_path, input_instruction[i], 130 | start_position = [random.uniform(1.2, 1.41), random.uniform(-1.2, -1.41)], 131 | end_position = [random.uniform(-0.2, 0.2), random.uniform(1.2, 1.41)], 132 | syntactic_correct_loop = syntactic_correct_loop, 133 | semantic_correct_loop=semantic_correct_loop, 134 | model_name=model_name, 135 | domain='HouseWorld') 136 | if mark_syntactic == 1: 137 | f_STL_output.write('Syntactic correct' + '\n') 138 | f_STL_output.write(str(i+10) + '. ' + str(output_stl) + '\n\n') 139 | f_STL_output.write(str(TL_list) + '\n\n') 140 | if mark_syntactic == 0: 141 | f_STL_output.write('Syntactic wrong' + '\n') 142 | f_STL_output.write(str(i+10) + '. ' + str(output_stl) + '\n\n') 143 | f_STL_output.write(str(TL_list) + '\n\n') 144 | except: 145 | pass 146 | 147 | try: 148 | output_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic = NL2action(i+10, saving_path, input_instruction[i], 149 | start_position = [random.uniform(-1.4, -0.6), random.uniform(-0.1, -0.6)], 150 | end_position = [random.uniform(-0.2, 0.2), random.uniform(1.2, 1.41)], 151 | syntactic_correct_loop = syntactic_correct_loop, 152 | semantic_correct_loop=semantic_correct_loop, 153 | model_name=model_name, 154 | domain='HouseWorld') 155 | if mark_syntactic == 1: 156 | f_STL_output.write('Syntactic correct' + '\n') 157 | f_STL_output.write(str(i+10) + '. ' + str(output_stl) + '\n\n') 158 | f_STL_output.write(str(TL_list) + '\n\n') 159 | if mark_syntactic == 0: 160 | f_STL_output.write('Syntactic wrong' + '\n') 161 | f_STL_output.write(str(i+10) + '. ' + str(output_stl) + '\n\n') 162 | f_STL_output.write(str(TL_list) + '\n\n') 163 | except: 164 | pass 165 | 166 | f_STL_output.close() 167 | -------------------------------------------------------------------------------- /env_and_optimize_single_agent.py: -------------------------------------------------------------------------------- 1 | import copy 2 | import numpy as np 3 | from PWLPlan import plan, Node 4 | from vis import vis 5 | import time 6 | import os 7 | import openai 8 | from openai_func import * 9 | import ast 10 | import re 11 | 12 | def test(domain, input_stl_original, prop2block_dir, x0 = [-1., -1], goal = [1, 1],tmax = 50., vmax = 5.): 13 | input_stl = copy.deepcopy(input_stl_original) 14 | 15 | while not (len(input_stl) ==1 and type(input_stl[0]) != str): 16 | for i in range(len(input_stl) - 1, -1, -1): 17 | if type(input_stl[i]) != str: 18 | pass 19 | elif input_stl[i][:5] == 'enter': 20 | input_stl[i] = prop2block_dir['prop_' + input_stl[i][10:-1]][-1] 21 | phi = Node('mu', info={'A': input_stl[i][0], 'b': input_stl[i][1]}) 22 | input_stl.pop(i) 23 | input_stl.insert(i,phi) 24 | if i==0 or type(input_stl[i-1]) != str or not (input_stl[i-1][0:4]=='glob' and input_stl[i-1][0:4]=='fina'): 25 | phi_2 = Node('F', deps=[phi, ], info={'int': [0, tmax]}) 26 | input_stl.pop(i) 27 | input_stl.insert(i, phi_2) 28 | elif input_stl[i][:9] == 'not_enter': 29 | input_stl[i] = prop2block_dir['prop_' + input_stl[i][14:-1]][-1] 30 | phi = Node('negmu', info={'A': input_stl[i][0], 'b': input_stl[i][1]}) 31 | input_stl.pop(i) 32 | input_stl.insert(i, phi) 33 | if i==0 or type(input_stl[i-1]) != str: 34 | phi_2 = Node('A', deps=[phi, ], info={'int': [0, tmax]}) 35 | input_stl.pop(i) 36 | input_stl.insert(i, phi_2) 37 | elif input_stl[i] == 'and' or input_stl[i] == 'or': 38 | phi = Node(input_stl[i], deps=[input_stl[i+1], input_stl[i+2]]) 39 | input_stl.pop(i+2) 40 | input_stl.pop(i+1) 41 | input_stl.pop(i) 42 | input_stl.insert(i, phi) 43 | elif input_stl[i] == 'globally': 44 | phi = Node('A', deps=[input_stl[i+1], ], info={'int': [0, tmax]}) 45 | input_stl.pop(i+1) 46 | input_stl.pop(i) 47 | input_stl.insert(i, phi) 48 | elif input_stl[i] != 'globally' and input_stl[i].split(' ')[0] == 'globally': 49 | s = copy.deepcopy(input_stl[i]) 50 | # Find all instances of the pattern 51 | matches = re.findall(r'\[([^\]]+)\]', s) 52 | # For each match, split the string by comma and strip whitespace 53 | time_expressions = [item.strip() for match in matches for item in match.split(',')] 54 | # Convert numerical strings to integers and leave 'infinite' as string 55 | time_expressions = [int(item) if item.isdigit() else item for item in time_expressions] 56 | 57 | if len(time_expressions) == 2: 58 | time_int1 = int(time_expressions[0]) 59 | if time_expressions[1] == 'infinite': 60 | time_int2 = tmax 61 | else: 62 | time_int2 = time_expressions[1] 63 | else: print('error') 64 | phi = Node('A', deps=[input_stl[i+1], ], info={'int': [time_int1, time_int2]}) 65 | input_stl.pop(i+1) 66 | input_stl.pop(i) 67 | input_stl.insert(i, phi) 68 | elif input_stl[i] == 'finally': 69 | phi = Node('F', deps=[input_stl[i+1], ], info={'int': [0, tmax]}) 70 | input_stl.pop(i+1) 71 | input_stl.pop(i) 72 | input_stl.insert(i, phi) 73 | elif input_stl[i] != 'finally' and input_stl[i].split(' ')[0] == 'finally': 74 | s = copy.deepcopy(input_stl[i]) 75 | # Find all instances of the pattern 76 | matches = re.findall(r'\[([^\]]+)\]', s) 77 | # For each match, split the string by comma and strip whitespace 78 | time_expressions = [item.strip() for match in matches for item in match.split(',')] 79 | # Convert numerical strings to integers and leave 'infinite' as string 80 | time_expressions = [int(item) if item.isdigit() else item for item in time_expressions] 81 | 82 | if len(time_expressions) == 2: 83 | time_int1 = int(time_expressions[0]) 84 | if time_expressions[1] == 'infinite': 85 | time_int2 = tmax 86 | else: 87 | time_int2 = time_expressions[1] 88 | else: print('error') 89 | phi = Node('F', deps=[input_stl[i+1], ], info={'int': [time_int1, time_int2]}) 90 | input_stl.pop(i+1) 91 | input_stl.pop(i) 92 | input_stl.insert(i, phi) 93 | elif input_stl[i] == 'until': 94 | phi = Node('U', deps=[input_stl[i + 1], input_stl[i + 2]], info={'int': [0, tmax]}) 95 | input_stl.pop(i+2) 96 | input_stl.pop(i+1) 97 | input_stl.pop(i) 98 | input_stl.insert(i, phi) 99 | elif input_stl[i] != 'until' and input_stl[i].split(' ')[0] == 'until': 100 | s = copy.deepcopy(input_stl[i]) 101 | # Find all instances of the pattern 102 | matches = re.findall(r'\[([^\]]+)\]', s) 103 | # For each match, split the string by comma and strip whitespace 104 | time_expressions = [item.strip() for match in matches for item in match.split(',')] 105 | # Convert numerical strings to integers and leave 'infinite' as string 106 | time_expressions = [int(item) if item.isdigit() else item for item in time_expressions] 107 | 108 | if len(time_expressions) == 2: 109 | time_int1 = int(time_expressions[0]) 110 | if time_expressions[1] == 'infinite': 111 | time_int2 = tmax 112 | else: 113 | time_int2 = time_expressions[1] 114 | else: print('error') 115 | phi = Node('U', deps=[input_stl[i + 1], input_stl[i + 2]], info={'int': [time_int1, time_int2]}) 116 | input_stl.pop(i+2) 117 | input_stl.pop(i+1) 118 | input_stl.pop(i) 119 | input_stl.insert(i, phi) 120 | print('Finish parsing STL!') 121 | spec = input_stl[0] 122 | 123 | x0s = [x0,] 124 | specs = [spec,] 125 | goals = [goal, ] 126 | if domain == 'chip': 127 | PWL = plan(x0s, specs, bloat=0.18, MIPGap=0.99, num_segs=30, tmax=tmax, vmax=vmax) 128 | elif domain == 'HouseWorld': 129 | PWL = plan(x0s, specs, bloat=0.05, size=0.11 / 2, num_segs=20, tmax=tmax, vmax=vmax, hard_goals=goals) 130 | 131 | return x0s, PWL 132 | 133 | def NL2action(index, saving_path, original_sent = 'Go to one room.', start_position = [-0.5, -1.1], end_position = [1.15, 1.15], syntactic_correct_loop = True, semantic_correct_loop = True, model_name = 'gpt-4', environment = 'env1', domain = 'chip'): 134 | time_start_total = time.time() 135 | time_semantic = 0 136 | time_total = 0 137 | time_syntactic = 0 138 | semantic_iteration_times = 0 139 | syntactic_iteration_times = 0 140 | #print('\n\nStart the new round of NL2action!\n\n') 141 | wall_half_width = 0.1 142 | A = np.array([[-1, 0], [1, 0], [0, -1], [0, 1]]) 143 | 144 | if domain == 'chip': 145 | if environment == 'env1': 146 | # Chip environment1 147 | _doors = [] 148 | _doors.append(np.array([2, 2, 0, 1], dtype=np.float64)) 149 | _doors.append(np.array([6, 6, 5, 6], dtype=np.float64)) 150 | _doors.append(np.array([6, 8, 2, 2], dtype=np.float64)) 151 | _doors.append(np.array([0, 2, 4, 4], dtype=np.float64)) 152 | _doors.append(np.array([7, 8, 6, 6], dtype=np.float64)) 153 | 154 | doors = [] 155 | for index_env, door in enumerate(_doors): 156 | if door[0] == door[1]: 157 | door[0] -= wall_half_width 158 | door[1] += wall_half_width 159 | elif door[2] == door[3]: 160 | door[2] -= wall_half_width 161 | door[3] += wall_half_width 162 | else: 163 | raise ValueError('wrong shape for axis-aligned door') 164 | door *= np.array([-1, 1, -1, 1]) 165 | doors.append(door.tolist() + ['door' + str(index_env + 1)]) 166 | 167 | _keys = [] 168 | _keys.append(np.array([5, 1], dtype=np.float64)) 169 | _keys.append(np.array([3, 3], dtype=np.float64)) 170 | _keys.append(np.array([1, 1], dtype=np.float64)) 171 | _keys.append(np.array([7, 1], dtype=np.float64)) 172 | _keys.append(np.array([3, 5], dtype=np.float64)) 173 | 174 | keys = [] 175 | key_half_width = 0.55 176 | for index_env, key in enumerate(_keys): 177 | key = np.array( 178 | [-(key[0] - key_half_width), (key[0] + key_half_width), -(key[1] - key_half_width), 179 | (key[1] + key_half_width)]) 180 | keys.append(key.tolist() + ['key' + str(index_env + 1)]) 181 | 182 | goals = [] 183 | b = np.array([-0.5, 1.5, -6.5, 7.5], dtype=np.float64) 184 | goals.append(b.tolist() + ['goal']) 185 | b2 = np.array([-6.7, 7.5, -3.7, 4.5], dtype=np.float64) 186 | goals.append(b2.tolist() + ['goal']) 187 | 188 | _walls = [] 189 | 190 | _walls.append(np.array([0, 0, 0, 8], dtype=np.float64)) 191 | _walls.append(np.array([8, 8, 0, 8], dtype=np.float64)) 192 | _walls.append(np.array([0, 8, 0, 0], dtype=np.float64)) 193 | _walls.append(np.array([0, 8, 8, 8], dtype=np.float64)) 194 | _walls.append(np.array([0, 7, 6, 6], dtype=np.float64)) 195 | _walls.append(np.array([2, 2, 1, 4], dtype=np.float64)) 196 | _walls.append(np.array([2, 4, 4, 4], dtype=np.float64)) 197 | _walls.append(np.array([4, 4, 4, 6], dtype=np.float64)) 198 | _walls.append(np.array([6, 6, 0, 5], dtype=np.float64)) 199 | 200 | walls = [] 201 | for wall in _walls: 202 | if wall[0] == wall[1]: 203 | wall[0] -= wall_half_width 204 | wall[1] += wall_half_width 205 | elif wall[2] == wall[3]: 206 | wall[2] -= wall_half_width 207 | wall[3] += wall_half_width 208 | else: 209 | raise ValueError('wrong shape for axis-aligned wall') 210 | wall *= np.array([-1, 1, -1, 1]) 211 | walls.append(wall.tolist() + ['wall']) 212 | 213 | tag_and_shape = { 214 | 'green': keys, 215 | 'blue': goals, 216 | 'red': doors, 217 | 'black': walls} 218 | elif environment == 'env2': 219 | # Chip environment2 220 | 221 | _walls = [] 222 | 223 | _walls.append(np.array([0, 0, 0, 8], dtype=np.float64)) 224 | _walls.append(np.array([8, 8, 0, 8], dtype=np.float64)) 225 | _walls.append(np.array([0, 8, 0, 0], dtype=np.float64)) 226 | _walls.append(np.array([0, 8, 8, 8], dtype=np.float64)) 227 | _walls.append(np.array([3.5, 7, 6, 6], dtype=np.float64)) 228 | _walls.append(np.array([0, 2.5, 6, 6], dtype=np.float64)) 229 | _walls.append(np.array([2, 4, 1, 1], dtype=np.float64)) 230 | _walls.append(np.array([5, 6, 1, 1], dtype=np.float64)) 231 | _walls.append(np.array([2, 2, 1, 4], dtype=np.float64)) 232 | _walls.append(np.array([2, 4, 4, 4], dtype=np.float64)) 233 | _walls.append(np.array([4, 4, 4, 6], dtype=np.float64)) 234 | _walls.append(np.array([2, 2, 4, 6], dtype=np.float64)) 235 | _walls.append(np.array([6, 6, 0, 5], dtype=np.float64)) 236 | 237 | walls = [] 238 | for wall in _walls: 239 | if wall[0] == wall[1]: 240 | wall[0] -= wall_half_width 241 | wall[1] += wall_half_width 242 | elif wall[2] == wall[3]: 243 | wall[2] -= wall_half_width 244 | wall[3] += wall_half_width 245 | else: 246 | raise ValueError('wrong shape for axis-aligned wall') 247 | wall *= np.array([-1, 1, -1, 1]) 248 | walls.append(wall.tolist() + ['wall']) 249 | 250 | tag_and_shape = { 251 | 'red': [[-2.5, 3.5, -5.9, 6.1, 'door1'], [-5.9, 6.1, -5, 6, 'door2'], [-4, 5, -0.9, 1.1, 'door3']], 252 | 'green': [[-2.5, 2.9, -4.5, 4.9, 'key1'], [-3.4, 3.8, -5.4, 5.8, 'key2'], [-6.5, 7.5, -1.5, 2.5, 'key3']], 253 | 'black': walls, 254 | 'blue': [[-0.5, 1.5, -6.5, 7.5, 'goal'], [-2.5, 3.5, -1.7, 2.7, 'goal'], [-4.5, 5.5, -2, 3, 'goal'], 255 | [-0.5, 1.5, -3.5, 4.5, 'goal']]} 256 | elif environment == 'env3': 257 | # Chip environment3 258 | _walls = [] 259 | 260 | _walls.append(np.array([0, 0, 0, 8], dtype=np.float64)) 261 | _walls.append(np.array([8, 8, 0, 8], dtype=np.float64)) 262 | _walls.append(np.array([0, 8, 0, 0], dtype=np.float64)) 263 | _walls.append(np.array([0, 8, 8, 8], dtype=np.float64)) 264 | _walls.append(np.array([3.5, 7, 6, 6], dtype=np.float64)) 265 | _walls.append(np.array([0, 2.5, 6, 6], dtype=np.float64)) 266 | _walls.append(np.array([2, 4, 1, 1], dtype=np.float64)) 267 | _walls.append(np.array([5, 6, 1, 1], dtype=np.float64)) 268 | _walls.append(np.array([2, 2, 1, 4], dtype=np.float64)) 269 | _walls.append(np.array([2, 4, 4, 4], dtype=np.float64)) 270 | _walls.append(np.array([4, 4, 4, 6], dtype=np.float64)) 271 | _walls.append(np.array([2, 2, 4, 6], dtype=np.float64)) 272 | _walls.append(np.array([6, 6, 0, 5], dtype=np.float64)) 273 | 274 | wall_data = [] 275 | for wall in _walls: 276 | if wall[0] == wall[1]: 277 | wall[0] -= wall_half_width 278 | wall[1] += wall_half_width 279 | elif wall[2] == wall[3]: 280 | wall[2] -= wall_half_width 281 | wall[3] += wall_half_width 282 | else: 283 | raise ValueError('wrong shape for axis-aligned wall') 284 | wall *= np.array([-1, 1, -1, 1]) 285 | wall_data.append(wall.tolist()) 286 | 287 | walls_with_tags = [data + ['wall'] for data in wall_data] 288 | 289 | tag_and_shape = { 290 | 'red': [[-2.5, 3.5, -5.9, 6.1, 'door1'], [-7, 8, -5.9, 6.1, 'door2'], [-5.9, 6.1, -5, 6, 'door3'], 291 | [-4, 5, -0.9, 1.1, 'door4'], [-6, 8, -0.9, 1.1, 'door5'], [0, 2, -2.9, 3.1, 'door6'], 292 | [0, 2, -1.9, 2.1, 'door7']], 293 | 'green': [[-2.5, 2.9, -4.5, 4.9, 'key1'], [-3.2, 3.8, -7.2, 7.8, 'key2'], [-3.4, 3.8, -5.4, 5.8, 'key3'], 294 | [-6.5, 7.5, -1.5, 2.5, 'key4'], [-4.5, 5.5, -6.5, 7.5, 'key5'], [-2.2, 2.9, -5.2, 5.9, 'key6'], 295 | [-7.3, 7.8, -0.2, 0.7, 'key7']], 296 | 'black': walls_with_tags, 297 | 'blue': [[-0.5, 1.5, -6.5, 7.5, 'goal'], [-2.5, 3.5, -1.7, 2.7, 'goal'], [-4.5, 5.5, -2, 3, 'goal'], 298 | [-0.5, 1.5, -3.5, 4.5, 'goal'], [-6.5, 7.1, -0.2, 0.8, 'goal']]} 299 | 300 | elif domain == 'HouseWorld': 301 | wall_half_width = 0.05 302 | A = np.array([[-1, 0], [1, 0], [0, -1], [0, 1]]) 303 | walls = [] 304 | 305 | wall_half_len = 1.5 306 | walls.append(np.array([-wall_half_len, -wall_half_len, -wall_half_len, wall_half_len], dtype=np.float64)) 307 | walls.append(np.array([wall_half_len, wall_half_len, -wall_half_len, wall_half_len], dtype=np.float64)) 308 | walls.append(np.array([-wall_half_len, wall_half_len, -wall_half_len, -wall_half_len], dtype=np.float64)) 309 | walls.append(np.array([-wall_half_len, wall_half_len, wall_half_len, wall_half_len], dtype=np.float64)) 310 | 311 | wall_data = [] 312 | for wall in walls: 313 | if wall[0] == wall[1]: 314 | wall[0] -= wall_half_width 315 | wall[1] += wall_half_width 316 | elif wall[2] == wall[3]: 317 | wall[2] -= wall_half_width 318 | wall[3] += wall_half_width 319 | else: 320 | raise ValueError('wrong shape for axis-aligned wall') 321 | wall *= np.array([-1, 1, -1, 1]) 322 | wall_data.append(wall.tolist()) 323 | 324 | walls_with_tags = [data + ['wall'] for data in wall_data] 325 | 326 | # LTLMOP environment 327 | tag_and_shape = {'cyan': [[1.2, -0.8, 1.4, -0.7, 'Kitchen']], 'red': [[0, 0.9, 1.4, -0.7, 'RestRoom2']], 328 | 'green': [[-0.2, 1.43, -0.8, 1.43, 'MasterBedroom']], 329 | 'pink': [[-0.6, 1.43, -0.2, 0.8, 'Bedroom']], 330 | 'blue': [[0.5, 0.5, 0.5, 0.5, 'LivingRoom'], [1.2, -0.7, 0.05, 0.5, 'ExerciseRoom']], 331 | 'yellow': [[1.4, -0.2, -0.8, 1.43, 'RestRoom']], 332 | 'purple': [[0.7, -0.3, 1.4, -0.8, 'DiningRoom']], 333 | 'black': walls_with_tags} 334 | else: 335 | raise ValueError('unknown domain') 336 | 337 | # Start the parsing and planning 338 | #print('Start the parsing and planning') 339 | plots = [] 340 | prop2block_dir = {} 341 | 342 | i = 0 343 | for color, block_array in tag_and_shape.items(): 344 | for block_item_list in block_array: 345 | block_item = block_item_list[:-1] 346 | block_item_func_str = block_item_list[-1] 347 | B_item = (A, np.array(block_item, dtype=np.float64)) 348 | plots.append([[B_item, ], color, block_item_func_str]) 349 | i = i + 1 350 | prop2block_dir['prop_' + str(i)] = [color, block_item, block_item_func_str, B_item] 351 | 352 | # First round 353 | action_list = 'available scene objects: ' 354 | for i in range(len(prop2block_dir.items())): 355 | prop_item_list = prop2block_dir['prop_'+str(i+1)] 356 | action_list += ('[name : room' + str(i+1) + ', color: ' + prop_item_list[0] + ', function: ' + prop_item_list[2] + ', position and size: ' + '(' + str(prop_item_list[1])[1:-1] +')' + '], ') 357 | 358 | action_list = action_list[:-2] + '\n' 359 | action_list += 'available actions: [enter(), not_enter()]' 360 | 361 | part1="Please help me detect the actions in the sentence and transform the action expression into corresponding Signal Temporal Logics (STL) representation with closest meanings. The operators are: imply, and, equal, until, globally, finally, or. The STL should follow pre-order expression. The until, finally, and globally operators can be appended with time expressions. The time is integer or 'infinite' to express infinite time. Some examples of natural language and STL pairs are:\nnatural language: only under the case of going to room2, will entering room_1 not happen\nSTL: ['imply', 'not_enter(room_1)', 'enter(room_2)']\n\nnatural language: going into room_1 always follows with entering room_2.\nSTL: ['globally', 'imply', 'enter(room_1)', 'finally', 'enter(room_2)']\n\nnatural language: only under the case of going to room2, will entering room_1 not happen\nSTL: ['imply', 'not_enter(room_1)', 'enter(room_2)']\n\nnatural language: Maintain enter(room_1) until enter(room_2) is satisfied.\nSTL: ['globally', 'until', 'enter(room_1)', 'enter(room_2)']\n\nnatural language: Go to room1 and always avoid both room2 and room3.\nSTL: ['and', 'finally', 'enter(room_1)', 'globally', 'and', 'negation', 'enter(room_2)', 'negation', 'enter(room_3)']\n\nnatural language: If reaching room1 happens before reaching room_3 then start room_2 and cancel ( room_4 ) anytime within 0 to 10 timesteps.\nSTL: ['globally', 'imply', 'and', 'enter(room_1)', 'finally', 'enter(room_3)', 'and', 'enter(room_2)', 'finally', 'negation', 'enter(room_4)']\n\nnatural language: For time steps between 0 and 20, until enter(room_1) and enter(room_2) is true, don’t start enter(room_3).\nSTL: ['globally [0,20]', 'until', 'negation', 'enter(room_3)', 'and', 'enter(room_1)', 'enter(room_2)']\n\nnatural language: If room_1 and room_2 and not room_3 or room_4, then room_5 happens after 10 timesteps.\nSTL: ['imply', 'and', 'and', 'enter(room_1)', 'enter(room_2)', 'negation', 'or', 'enter(room_3)', 'enter(room_4)', 'finally [10,infinite]', 'enter(room_5)']\n\nI will give you the position and size of each box in the whole environment and the instruction is to enter or avoid the box. Each box is of square shape, I will give you (x_start, x_end, y_start, y_end) to describe the shape of square. x_start, x_end denote the boundary of squares in x coordinates. y_start, y_end denote the boundary of squares in y coordinates.\n\nHere are examples:\nInput:\navailable scene objects: ['name' : room1, 'color': yellow, 'position and size': (-1, -0.7, -0.25, 0.5)], ['name' : room2, 'color': red, 'position and size': (0, 0.9, -1, -0.5)], ['name' : room3, 'color': green, 'position and size': (0.2, 0.7, 0.8, 1.2)], ['name' : room4, 'color': blue, 'position and size': (-0.4, 0.4, -0.4, 0.4)], ['name' : room5, 'color': blue, 'position and size': (0.6, 0.8, -0.2, 0.2)],\navailable actions: [enter(), not_enter()]\nsentence: Finally reach the green region, and you have to go to cyan area ahead to enter yellow room.\nOutput:\ntransformed sentence: finally prop_1 and prop_2.\n'prop_1' : ['enter(room3)'] ; 'prop_2' : ['until', 'negation', 'enter(room1)', 'enter(room4)']\n\nInput:\navailable scene objects: ['name' : room1, 'function': key1 for door1], ['name' : room2, 'function': key2 for door2], ['name' : room3, 'function': key3 for door3], ['name' : room4, 'function': key4 for door4], ['name' : room5, 'function': key5 for door5], ['name' : room6, 'function': door1], ['name' : room7, 'function': door2], ['name' : room8, 'function': door3], ['name' : room9, 'function': door4], ['name' : room10, 'function': door5], ['name' : room11, 'function': goal], ['name' : room12, 'function': walls],\navailable actions: [enter(), not_enter()]\nsentence: Finally reach the goal region, and you have to get the corresponding key ahead to open each door, such as entering key1 before door1, remember not touch the wall at any time.\nOutput:\ntransformed sentence: finally prop_1 and prop_2 and globally prop_3.\n'prop_1' : ['enter(room11)'] ; 'prop_2' : ['and', 'and', 'and', 'and', 'until', 'negation', 'enter(room6)', 'enter(room1)', 'until', 'negation', 'enter(room7)', 'enter(room2)', 'until', 'negation', 'enter(room8)', 'enter(room3)', 'until', 'negation', 'enter(room9)', 'enter(room4)', 'until', 'negation', 'enter(room10)', 'enter(room5)'] ; 'prop_3' : ['not_enter(room12)']\n\nInput:\navailable scene objects: ['name' : room1, 'function': goal region, 'color': green], ['name' : room2, 'function': goal region, 'color': green], ['name' : room3, 'function': goal region, 'color': green], ['name' : room7, 'function': charging station, 'color': blue], ['name' : room12, 'function': walls],\navailable actions: [enter(), not_enter()]\nsentence: room_1, then room_2 and stay there for 5 seconds, remember always not room_12.\nOutput:\ntransformed sentence: prop_1 and prop_2 and globally prop_3.\n'prop_1' : ['enter(room1)'] ; 'prop_2' : ['finally', 'globally [0,5]', 'prop_2'] ; 'prop_3' : ['not_enter(room12)']\n\nInput:\navailable scene objects: ['name' : room1, 'function': goal region, 'color': green], ['name' : room2, 'function': goal region, 'color': green], ['name' : room3, 'function': goal region, 'color': green], ['name' : room7, 'function': charging station, 'color': blue], ['name' : room12, 'function': walls],\navailable actions: [enter(), not_enter()]\nsentence: Every rover should room_3 within 40 time units every time they leave room_7. After room_1, the rover should room_2 within 20 time units.\nOutput:\ntransformed sentence: globally prop_1 and prop_2.\n'prop_1' : ['imply', 'not_enter(room7)', 'finally [0,40]', 'enter(room3)'] ; 'prop_2' : ['imply', 'enter(room1)', 'finally [0,20]', 'enter(room2)']\n\nInput:\navailable scene objects: ['name' : room1, 'function': goal region, 'color': green], ['name' : room2, 'function': goal region, 'color': green], ['name' : room3, 'function': goal region, 'color': green], ['name' : room4, 'function': goal region, 'color': green], ['name' : room5, 'function': transmitting region, 'color': green], ['name' : room6, 'function': transmitting region, 'color': green], ['name' : room7, 'function': charging station, 'color': blue], ['name' : room12, 'function': walls],\navailable actions: [enter(), not_enter()]\nsentence:1) Every rover should visit the charging station (blue) within 10 time units every time they leave the charging station; 2) After visiting a goal region, the rover should visit a transmitter (yellow) within 5 time units, to transmit the collected data to the remote control; 3) The rovers should avoid the walls (black) and each other. 4) visit all the goal regions\nOutput:\ntransformed sentence: globally prop_1 and globally prop_2 and globally prop_3 and prop_4.\n'prop_1' : ['imply', 'not_enter(room7)', 'finally [0,10]', 'enter(room7)'] ; 'prop_2' : ['imply', 'or', 'or', 'or', 'enter(room1)', 'enter(room2)', 'enter(room3)', 'enter(room4)', 'finally [0,5]', 'or', 'enter(room5)', 'enter(room6)'] ; 'prop_3' : ['not_enter(room12)'] ; 'prop_4' : ['and', 'and', 'and', 'enter(room1)', 'enter(room2)', 'enter(room3)', 'enter(room4)']\n\nInput:\navailable scene objects: [name : room1, color: cyan, function: Kitchen, position and size: (1.2, -0.8, 1.4, -0.7)], [name : room2, color: red, function: RestRoom2, position and size: (0, 0.9, 1.4, -0.7)], [name : room3, color: green, function: MasterBedroom, position and size: (-0.2, 1.43, -0.8, 1.43)], [name : room4, color: pink, function: Bedroom, position and size: (-0.6, 1.43, -0.2, 0.8)], [name : room5, color: blue, function: LivingRoom, position and size: (0.5, 0.5, 0.5, 0.5)], [name : room6, color: blue, function: ExerciseRoom, position and size: (1.2, -0.7, 0.05, 0.5)], [name : room7, color: yellow, function: RestRoom, position and size: (1.4, -0.2, -0.8, 1.43)], [name : room8, color: purple, function: DiningRoom, position and size: (0.7, -0.3, 1.4, -0.8)]\navailable actions: [enter(), not_enter()]\nsentence: Go to one room with cyan color, then enter the bedroom and stay there for 5 seconds, finally reach the restroom. remember always do not touch the two true blue areas.\nOutput:\ntransformed sentence: prop_1 and prop_2 and finally prop_3 and globally prop_4.\n'prop_1' : ['enter(room1)'] ; 'prop_2' : ['finally', 'globally [0,5]', 'enter(room4)'] ; 'prop_3' : ['enter(room7)'] ; 'prop_4' : ['and', 'not_enter(room5)', 'not_enter(room6)']\n\n" 362 | 363 | part3 = '\nsentence: ' 364 | user_prompt_1 = part1 + 'Input:\n' + action_list + part3 + original_sent + '\nOutput: ' 365 | #print(user_prompt_1) 366 | if model_name == 'gpt-4': 367 | AP_and_lifted_NL = GPT_response_first_round(user_prompt_1, 'gpt-4') 368 | elif model_name == 'gpt-3': 369 | AP_and_lifted_NL = GPT_response_GPT_3(user_prompt_1) 370 | print(AP_and_lifted_NL) 371 | 372 | lifted_NL, AP_dict = parse_string(AP_and_lifted_NL) 373 | 374 | print(lifted_NL) 375 | TL_list = ast.literal_eval(GPT_NL2TL_preorder(lifted_NL, model_name_NL2TL = model_name)) 376 | print(AP_dict) 377 | print(TL_list) 378 | 379 | time_syntactic_start = time.time() 380 | if syntactic_correct_loop == True: 381 | try: 382 | AP_and_lifted_NL, syntactic_iteration_times = func_syntactic_correct_loop(model_name, user_prompt_1, AP_and_lifted_NL) 383 | lifted_NL, AP_dict = parse_string(AP_and_lifted_NL) 384 | TL_list = ast.literal_eval(GPT_NL2TL_preorder(lifted_NL, model_name_NL2TL = model_name)) 385 | if check_syntactic_correct(TL_list) != 'correct': 386 | # Second round 387 | if check_syntactic_correct(TL_list) != 'correct' and type(check_syntactic_correct(TL_list)) == int: 388 | if check_syntactic_correct(TL_list) > 1: 389 | TL_list = ['and'] * (check_syntactic_correct(TL_list) - 1) + TL_list 390 | elif check_syntactic_correct(TL_list) < 1: 391 | TL_list = TL_list[abs(check_syntactic_correct(TL_list)-1):] 392 | except: 393 | pass 394 | time_syntactic_end = time.time() 395 | time_syntactic = time_syntactic_end - time_syntactic_start 396 | 397 | # transform TL_list into input_stl 398 | input_stl = [] 399 | for item in TL_list: 400 | if item[0:4] == 'prop': 401 | input_stl += AP_dict[item] 402 | else: 403 | input_stl += [item] 404 | 405 | input_stl = filter_negation_imply(input_stl) 406 | print('Input lifted TL: ', TL_list) 407 | print('input stl for list check: ', input_stl) 408 | 409 | if check_syntactic_correct_inverse_order(input_stl) == 'correct' and not 'negation' in input_stl and not 'imply' in input_stl: 410 | mark_syntactic = 1 411 | print('Input_NL: ', lifted_NL) 412 | print('Output STL: ', input_stl) 413 | _, PWLs = test(domain, input_stl, prop2block_dir, x0 = start_position, goal = end_position) 414 | if PWLs != [None,]: 415 | #results = vis(plots, PWLs) 416 | PWL = PWLs[0] 417 | position_time_list = [[P[0][0], P[0][1], P[1]] for P in PWL] 418 | with open(saving_path + '/myfile' + str(index) +'.txt', 'wb') as f: 419 | # save your array into the file 420 | np.savetxt(f, np.array(position_time_list), fmt='%f') 421 | f.close() 422 | 423 | trajectory_len_total = trajectory_len_cal(PWLs) 424 | print('trajectory_len_total: ', trajectory_len_total) 425 | 426 | time_semantic_start = time.time() 427 | if semantic_correct_loop == True: 428 | output_stl_1 = copy.deepcopy(input_stl) 429 | 430 | for index_semantic in range(3): 431 | semantic_iteration_times += 1 432 | print('\nSemantic loop' + str(index_semantic + 1) + ':\n\n') 433 | #print(position_time_list) 434 | #print('position_time_list length: ', len(position_time_list)) 435 | state_time_list = judge_trajectory_output_state(tag_and_shape, position_time_list, divide_path_time_ratio=1) 436 | state_time_list_abbre = abbreviate_list_state_check(state_time_list) 437 | user_prompt_2_original = '[' 438 | for index_abbre, item in enumerate(state_time_list_abbre): 439 | if index_abbre != len(state_time_list_abbre) - 1: 440 | user_prompt_2_original += 'in ' + str(item[0]) + ' ' + str(item[1]) + ' at time ' + str( 441 | item[2]) + ', ' 442 | else: 443 | user_prompt_2_original += 'in ' + str(item[0]) + ' ' + str(item[1]) + ' at time ' + str( 444 | item[2]) + '].' 445 | 446 | user_prompt_2 = 'Based on your predicted STL ' + str( 447 | output_stl_1) + ' , the state sequence [[location, time]] of the generated trajectory is: ' + user_prompt_2_original + \ 448 | '\n \nPlease print the initial instruction again and check whether this state sequence follows the instruction. ' \ 449 | 'Let us do it step by step, first specifically explain the semantic meanings of the instruction, and then list all the available rooms in the given environment, ' \ 450 | 'then determine the rooms planned to visit or avoid and whether the trajectory is consistent. ' \ 451 | 'Next modify or keep the final STL based on above analysis. First output your thinking steps and in the last line output the full final STL beginning with STL: . ' \ 452 | '\nOutput:' 453 | LLM_response2 = GPT_response_second_round(user_prompt_1, AP_and_lifted_NL, user_prompt_2, 454 | model_name_NL2TL=model_name) 455 | output_stl_after_semantic = extract_list_for_semantic_check_LLM_response(LLM_response2) 456 | if check_syntactic_correct(output_stl_after_semantic) != 'correct': 457 | # Second round 458 | if check_syntactic_correct(output_stl_after_semantic) != 'correct' and type( 459 | check_syntactic_correct(output_stl_after_semantic)) == int: 460 | if check_syntactic_correct(output_stl_after_semantic) > 1: 461 | output_stl_after_semantic = ['and'] * (check_syntactic_correct(output_stl_after_semantic) - 1) + output_stl_after_semantic 462 | elif check_syntactic_correct(output_stl_after_semantic) < 1: 463 | output_stl_after_semantic = output_stl_after_semantic[abs(check_syntactic_correct(output_stl_after_semantic) - 1):] 464 | 465 | print('The updated STL in semantic check iteration' + str(index_semantic) + ' is: ', output_stl_after_semantic) 466 | if output_stl_after_semantic == output_stl_1: 467 | print('The updated STL in semantic check iteration' + str(index_semantic) + ' is the same as the previous one, stop semantic check!') 468 | break 469 | else: 470 | print('The updated STL in semantic check iteration' + str(index_semantic) + ' is different from the previous one, continue semantic check!') 471 | output_stl_1 = copy.deepcopy(output_stl_after_semantic) 472 | input_stl = copy.deepcopy(output_stl_after_semantic) 473 | 474 | if check_syntactic_correct_inverse_order( 475 | input_stl) == 'correct' and not 'negation' in input_stl and not 'imply' in input_stl: 476 | _, PWLs = test(domain, input_stl, prop2block_dir, x0=start_position, goal=end_position) 477 | if PWLs != [None, ]: 478 | # results = vis(plots, PWLs) 479 | PWL = PWLs[0] 480 | position_time_list = [[P[0][0], P[0][1], P[1]] for P in PWL] 481 | with open(saving_path + '/myfile' + str(index) + '.txt', 'wb') as f: 482 | # save your array into the file 483 | np.savetxt(f, np.array(position_time_list), fmt='%f') 484 | f.close() 485 | time_semantic_end = time.time() 486 | time_semantic = time_semantic_end - time_semantic_start 487 | 488 | else: # PWLs == [None,] 489 | 490 | with open(saving_path + '/myfile' + str(index) +'.txt', 'wb') as f: 491 | # save your array into the file 492 | np.savetxt(f, np.array([0,0,0]), fmt='%f') 493 | f.close() 494 | print('No solution found!') 495 | else: 496 | mark_syntactic = 0 497 | print('Input_STL is wrong!') 498 | print(input_stl) 499 | with open(saving_path + '/myfile' + str(index) + '.txt', 500 | 'wb') as f: 501 | # save your array into the file 502 | np.savetxt(f, np.array([0,0]), fmt='%f') 503 | time_end_total = time.time() 504 | print('Total time: ', time_end_total - time_start_total) 505 | print('Syntactic check time: ', time_syntactic) 506 | print('Semantic check time: ', time_semantic) 507 | time_total = time_end_total - time_start_total 508 | with open(saving_path + '/myfile_time_consume' + str(index) + '.txt', 'w') as f: 509 | # save your array into the file 510 | f.write('Total time: ' + str(time_total) +'\n') 511 | f.write('Syntactic time: ' + str(time_syntactic) + '\n') 512 | f.write('Semantic time: ' + str(time_semantic) + '\n') 513 | f.write('Syntactic check iteration: ' + str(syntactic_iteration_times) + '\n') 514 | f.write('Semantic check iteration: ' + str(semantic_iteration_times)) 515 | return input_stl, TL_list, mark_syntactic, time_total, time_syntactic, time_semantic 516 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent1.txt: -------------------------------------------------------------------------------- 1 | Proceed towards the green bedroom, and then make your way to the yellow bathroom. 2 | 3 | Proceed to the green-colored sleeping room, then move on to the yellow washroom. 4 | 5 | First, move into the bedroom painted green, then continue to the restroom colored yellow. 6 | 7 | Start by heading into the green sleeping quarters, then progress to the restroom in yellow. 8 | 9 | Commence by making your way to the emerald bedroom, and subsequently, towards the yellow restroom. 10 | 11 | First, steer towards the green master room, afterwards proceed to the washroom in yellow. 12 | 13 | Embark towards the bedroom of green hue, and then advance to the restroom tinted in yellow. 14 | 15 | Start off by moving into the green bedroom, then continue towards the bathroom with a yellow theme. 16 | 17 | Make a beeline to the bedroom that's green, then proceed to the yellow-toned restroom. 18 | 19 | Take the path leading to the bedroom in green, and then continue towards the restroom bathed in yellow. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent10.txt: -------------------------------------------------------------------------------- 1 | Be sure to enter every room at least once. However, before proceeding to any other room, make sure to visit the living room. Ultimately, your journey should conclude in the smaller blue room. 2 | 3 | Every room should be visited at least once, but it's essential to stop by the living room before heading to the subsequent room. Your final destination should be the smaller blue room. 4 | 5 | You must check out each room at least once, but ensure that you always pass through the living room before you move to the next. The journey should finally lead you to the smaller blue room. 6 | 7 | Make a point to pass through every room at least once, always remembering to return to the living room before going on to the next room. Your final stop should be in the smaller blue room. 8 | 9 | Remember to pay a visit to every room at least once, however, don't forget to always return to the living room before going to the next. Conclude your tour in the smaller blue room. 10 | 11 | Ensure that you tour each room at least once, with the stipulation that you must always swing by the living room prior to entering the next room. In the end, your tour should finish in the smaller blue room. 12 | 13 | Go through every room at least once, but make a habit of always stepping into the living room before you proceed to the next room. Your route should eventually bring you to the smaller blue room. 14 | 15 | It's required to explore each room a minimum of one time, but make sure to stop off at the living room prior to moving on to the next. Your final stop will be in the smaller blue room. 16 | 17 | Make sure to inspect each room at least once, but always make your way back to the living room before stepping into the next. The final room to visit should be the smaller blue one. 18 | 19 | Venture into each room no less than once, always ensuring to pop into the living room before moving on to the next. Your exploration should culminate in the smaller blue room. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent2.txt: -------------------------------------------------------------------------------- 1 | Journey towards the mustard-colored lavatory, followed by a trip to the rosy-hued sleeping quarters. Make sure to explore both the culinary space and the eating area. Conclude your exploration in the crimson washroom. 2 | 3 | Make your way to the bathroom colored in hues of gold, then proceed towards the blush-tinted boudoir. Spend time in both the space for cooking and the room meant for dining. Finally, terminate your tour in the scarlet restroom. 4 | 5 | Set course for the restroom painted in sunflower yellow, subsequently heading to the bedroom with a pinkish tone. Be sure to pop into the room for cooking and the place for meals. Ultimately, wrap up your journey in the restroom adorned in ruby red. 6 | 7 | Begin by heading towards the canary yellow toilet, and follow this up by moving to the bedroom bearing a blush pink tone. Remember to drop by both the area for food preparation and the space where meals are served. Round off your circuit in the bold, red bathroom. 8 | 9 | Direct your steps to the bathroom that shines with a golden hue, then navigate to the candy-floss pink bedroom. Make it a point to visit the cooking area as well as the meal serving room. Your voyage should terminate in the fiery red washroom. 10 | 11 | Commence your journey in the lemon-hued bathroom, then transition to the rose-pink sleeping area. Check out both the food preparation space and the room set for dining. Bring your tour to a close in the bathroom of a vibrant red. 12 | 13 | Head first towards the golden restroom, then proceed to the soft pink bedroom. Don't miss out on the area for cooking and the place set aside for dining. Round off your trek in the strong red bathroom. 14 | 15 | Embark on a trip to the restroom decorated in buttercup yellow, and then transition to the room of rest shaded in pastel pink. Ensure you experience both the cookery and the place of eating. Wrap up in the washroom that's rich in a red hue. 16 | 17 | Move towards the amber-colored bathroom, followed by a journey to the powder pink sleep space. Don't forget to peruse both the place for culinary actions and the dining location. Culminate your expedition in the bathroom with a bold red touch. 18 | 19 | Take a trip to the sunny yellow bathroom, and then migrate to the flamingo pink resting area. Be sure to pay a visit to both the kitchen and the dining hall. Conclude your itinerary in the bathroom displaying a striking red. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent3.txt: -------------------------------------------------------------------------------- 1 | Make your way to the green bedroom, and from there, proceed to the yellow restroom, but it's important not to disturb the livingroom at all. 2 | 3 | Proceed directly into the green bedroom, next make your way to the yellow restroom, but be sure to stay clear of the livingroom at all times. 4 | 5 | Head first to the green bedroom and subsequently visit the yellow restroom, yet be mindful to keep away from the livingroom completely. 6 | 7 | The green bedroom should be your first stop, followed by the yellow restroom, but it's crucial to avoid any interaction with the livingroom. 8 | 9 | Your route should begin with the green bedroom, move on to the yellow restroom, but never include a visit to the livingroom. 10 | 11 | Embark towards the green bedroom, then transition towards the yellow restroom, however, steer clear of the livingroom throughout. 12 | 13 | Your journey should initiate from the green bedroom, then lead you to the yellow restroom, but a detour to the livingroom should be excluded at all times. 14 | 15 | Commence your trip at the green bedroom, follow up with the yellow restroom, but please don't venture into the livingroom. 16 | 17 | Firstly, find yourself in the green bedroom and thereafter proceed to the yellow restroom, but make sure to bypass the livingroom. 18 | 19 | Set your course to the green bedroom first, then make a beeline for the yellow restroom, but it's imperative not to meddle with the livingroom. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent4.txt: -------------------------------------------------------------------------------- 1 | Make your way to the room painted in cyan, proceed into the bedroom and linger there for 5 seconds, and then make your way to the restroom. Be sure to avoid contact with the two areas colored in true blue. 2 | 3 | Venture into the cyan-colored room, then step into the bedroom and pause there for a span of 5 seconds, afterward proceed towards the restroom. Be mindful to always avoid the two sections painted in true blue. 4 | 5 | Move into the room tinted with cyan, next, advance into the bedroom and remain there for exactly 5 seconds, and then navigate to the restroom. Remember, do not come in contact with the two true blue colored zones. 6 | 7 | Proceed towards the room painted cyan, from there, go into the bedroom and stay for a quick 5 seconds, then find your way to the restroom. Do remember to keep clear of the two areas adorned in true blue. 8 | 9 | Navigate to the cyan shaded room, next, transition to the bedroom and wait there for a count of 5 seconds, then head to the restroom. Remember to always steer clear of the two zones colored in true blue. 10 | 11 | Enter the room decorated in cyan, then journey into the bedroom and pause there for 5 seconds, before moving to the restroom. Always bear in mind not to touch the two regions painted in true blue. 12 | 13 | Head to the room adorned in cyan, then go into the bedroom and hold still there for a brief 5 seconds, afterward move on to the restroom. Always remember not to interact with the two true blue sections. 14 | 15 | Find your way to the room colored in cyan, then proceed to the bedroom and linger there for a short 5 seconds, after that, make your way to the restroom. Keep in mind to always avoid the two spots tinted in true blue. 16 | 17 | Advance to the room displaying a cyan hue, then progress into the bedroom and stay stationary there for 5 seconds, and finally, arrive at the restroom. Always take care not to touch the two true blue painted areas. 18 | 19 | Make your path towards the room with a cyan hue, then migrate to the bedroom and hold there for 5 seconds, and finally, proceed to the restroom. Always remember, do not touch the two distinct areas shaded in true blue. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent5.txt: -------------------------------------------------------------------------------- 1 | Go to two spaces that possess a hue closely resembling red, but not exactly the intense, pure shade of red. 2 | 3 | Inspect two chambers with a color similar to red, yet not the pristine red shade. 4 | 5 | Check out two rooms that feature a color which is nearly red, but not an unadulterated shade of red. 6 | 7 | Make your way to two locations painted in a tone approximating red, but lacking the vibrancy of pure red. 8 | 9 | Explore two interiors with a pigment that's almost red, but not the absolute and clear-cut tone of red. 10 | 11 | Visit two enclosures whose color leans towards red, but it's not quite the quintessential red. 12 | 13 | Have a look at two spaces where the color is somewhat akin to red, yet not precisely the pure form of red. 14 | 15 | Venture into two rooms that are painted in a color nearing red, but not the exact bright, raw hue of red. 16 | 17 | Take a tour of two rooms having a color that gravitates towards red, but it's not the fundamental, vivid red. 18 | 19 | Step into two areas tinted with a hue that's nearly red, but it isn't the clear, unadulterated red. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent6.txt: -------------------------------------------------------------------------------- 1 | Explore all the chambers that are neither light pink nor cyan. 2 | 3 | Visit all spaces that don't have a light pink or cyan color. 4 | 5 | Make sure to explore every area that isn't colored in light pink or cyan. 6 | 7 | Take a tour of all the rooms that aren't painted in light pink or cyan. 8 | 9 | Do not skip any room that lacks the color light pink or cyan. 10 | 11 | Inspect all areas that are devoid of light pink or cyan hues. 12 | 13 | Check out every room unless it's painted light pink or cyan. 14 | 15 | Browse all locations that are not decorated in light pink or cyan. 16 | 17 | Scope out every space that isn't adorned in light pink or cyan. 18 | 19 | Survey all rooms except those colored light pink or cyan. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent7.txt: -------------------------------------------------------------------------------- 1 | Before stepping into any of the bathrooms, make sure you visit the kitchen first. Venture into the red and yellow rooms, but refrain from going into any room that's blue. 2 | 3 | Before you set foot in either bathroom, be sure to make a quick stop at the kitchen. While you're there, feel free to explore the red and yellow rooms, just steer clear of the blue ones. 4 | 5 | Prioritize a visit to the kitchen before making your way to any of the bathrooms. You are free to explore both the yellow and red rooms, but avoid the blue ones at all costs. 6 | 7 | Make sure the kitchen is your first stop before you consider entering the bathrooms. The red and yellow rooms are fine for you to enter, just make sure not to wander into any blue rooms. 8 | 9 | It's crucial that you head to the kitchen first before using any of the bathrooms. Feel free to roam around in the yellow and red rooms, just make sure to avoid any rooms colored blue. 10 | 11 | Before setting foot in the bathrooms, make your way to the kitchen. Access the rooms painted in red and yellow, but stay away from the blue rooms. 12 | 13 | Ensure you make a pit stop in the kitchen before heading towards any bathroom. The yellow and red rooms are safe for you to venture into, however, you should avoid any room painted blue. 14 | 15 | Heading towards either bathroom? Make sure to visit the kitchen first. The yellow and red rooms are open for exploration, but keep off from any room bathed in blue. 16 | 17 | Ensure that your path to any of the bathrooms includes a detour through the kitchen. Feel free to explore the yellow and red rooms, but do not venture into any that are blue. 18 | 19 | Before you think about using either bathroom, visit the kitchen first. You're free to enter the red and yellow rooms, just be sure to avoid any rooms that are blue. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent8.txt: -------------------------------------------------------------------------------- 1 | Firstly, transition to the kitchen, afterwards advance to the bedroom ensuring you avoid all rooms painted blue. Ensure you remain in the bedroom for a minimum of 10 seconds, and then navigate back to the kitchen through the living room. 2 | 3 | Proceed to the kitchen first, then make your way to the bedroom, carefully steering clear of any rooms that are blue. Stay put in the bedroom for no less than 10 seconds, then take the route through the living room to return to the kitchen. 4 | 5 | First, head to the kitchen. From there, go to the bedroom but bypass any rooms that are colored blue. Remain in the bedroom for at least a ten-second interval, then go back to the kitchen by way of the living room. 6 | 7 | Commence by relocating to the kitchen, subsequently transition to the bedroom, avoiding any rooms adorned in blue. Once there, stay for a minimum duration of 10 seconds, then return to the kitchen through the living room. 8 | 9 | Start by moving into the kitchen, then progress towards the bedroom, making sure to circumnavigate any rooms that are blue. Spend at least 10 seconds in the bedroom, then travel back to the kitchen via the living room. 10 | 11 | Shift first to the kitchen, then proceed to the bedroom without crossing through any blue-decorated rooms. Maintain your position in the bedroom for a period not less than 10 seconds, before going back to the kitchen through the living room. 12 | 13 | Take your first step towards the kitchen, then journey to the bedroom, taking care not to walk into any rooms painted in blue. Hold your position in the bedroom for a count of at least 10 seconds, then backtrack to the kitchen using the living room as a pathway. 14 | 15 | Initially, find your way to the kitchen, then continue to the bedroom, being careful not to enter any rooms covered in blue. Stay stationary in the bedroom for a minimum span of 10 seconds, then reroute yourself back to the kitchen through the living room. 16 | 17 | Embark by heading to the kitchen, then make a beeline to the bedroom, dodging any blue-themed rooms. Ensure to linger in the bedroom for at least 10 seconds, then make your way back to the kitchen using the living room as your route. 18 | 19 | First, direct yourself to the kitchen, next, navigate to the bedroom, purposely avoiding any rooms painted blue. Commit to remaining in the bedroom for a minimum of 10 seconds, then follow the path through the living room back to the kitchen. 20 | -------------------------------------------------------------------------------- /experiment_result/HouseWorld/instr_dir/myfile_sent9.txt: -------------------------------------------------------------------------------- 1 | Make sure you check out all the rooms, but don't step foot in the pink room until you've been to the living room. 2 | 3 | Go through every room you come across, just hold off on the pink room until after you've hit the living room. 4 | 5 | You gotta see all the rooms, but save the pink room for after you've chilled in the living room. 6 | 7 | Pop into every room, but hold your horses on the pink room until after you've hung out in the living room. 8 | 9 | Be sure to poke your head into each room, but keep off the pink room until you've spent some time in the living room. 10 | 11 | Do a tour of all the rooms, but make sure the living room is checked off before you venture into the pink one. 12 | 13 | Scope out every room, but wait on the pink room until you've made a pit stop in the living room. 14 | 15 | Get a look at all the rooms, but don't you dare enter the pink room until after you've stopped by the living room. 16 | 17 | Make a round of all the rooms, just make sure to hit the living room before you head into the pink one. 18 | 19 | Give every room a once over, but the pink room is a no-go until you've lounged in the living room. 20 | -------------------------------------------------------------------------------- /experiment_result/chip/gpt-4-with-syntactic-semantic/sent0/myfile0.txt: -------------------------------------------------------------------------------- 1 | 0.000000 2 | 0.000000 3 | 0.000000 4 | -------------------------------------------------------------------------------- /experiment_result/chip/gpt-4-with-syntactic-semantic/sent0/myfile_time_consume0.txt: -------------------------------------------------------------------------------- 1 | Total time: 107.61521196365356 2 | Syntactic time: 51.34491801261902 3 | Semantic time: 0 4 | Syntactic check iteration: 4 5 | Semantic check iteration: 0 -------------------------------------------------------------------------------- /experiment_result/chip/gpt-4-with-syntactic-semantic/sent0/stl_output.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yongchao98/AutoTAMP/71e5000964dd234a4b08fbaf5e7703b85732bb8b/experiment_result/chip/gpt-4-with-syntactic-semantic/sent0/stl_output.txt -------------------------------------------------------------------------------- /experiment_result/chip/gpt4-with-syntactic/sent0/myfile0.txt: -------------------------------------------------------------------------------- 1 | 0.000000 2 | 0.000000 3 | 0.000000 4 | -------------------------------------------------------------------------------- /experiment_result/chip/gpt4-with-syntactic/sent0/myfile1.txt: -------------------------------------------------------------------------------- 1 | 0.000000 2 | 0.000000 3 | 0.000000 4 | -------------------------------------------------------------------------------- /experiment_result/chip/gpt4-with-syntactic/sent0/myfile4.txt: -------------------------------------------------------------------------------- 1 | 0.000000 2 | 0.000000 3 | 0.000000 4 | -------------------------------------------------------------------------------- /experiment_result/chip/gpt4-with-syntactic/sent0/stl_output.txt: -------------------------------------------------------------------------------- 1 | Syntactic correct 2 | 0. ['and', 'and', 'finally', 'and', 'enter(room6)', 'enter(room7)', 'globally', 'and', 'and', 'and', 'and', 'and', 'and', 'and', 'and', 'not_enter(room13)', 'not_enter(room14)', 'not_enter(room15)', 'not_enter(room16)', 'not_enter(room17)', 'not_enter(room18)', 'not_enter(room19)', 'not_enter(room20)', 'not_enter(room21)', 'and', 'and', 'and', 'and', 'until', 'not_enter(room8)', 'enter(room1)', 'until', 'not_enter(room9)', 'enter(room2)', 'until', 'not_enter(room10)', 'enter(room3)', 'until', 'not_enter(room11)', 'enter(room4)', 'until', 'not_enter(room12)', 'enter(room5)'] 3 | 4 | ['and', 'and', 'finally', 'prop_1', 'globally', 'prop_2', 'prop_3'] 5 | 6 | -------------------------------------------------------------------------------- /experiment_result/chip/instr_dir/myfile_sent1.txt: -------------------------------------------------------------------------------- 1 | Try to reach all the goals but you have to reach the corresponding key first to open the specific door. For example, you have to reach key1 ahead to open door1. Also remember always do not touch the walls. 2 | 3 | Make sure you snag every target, but remember, you've gotta grab the right key before you can get through its matching door. Like, key1 has to be in your hands before you can go through door1. Oh, and steer clear of those walls, got it? 4 | 5 | You're gonna wanna aim for all those objectives, but don't forget, each key is linked to a specific door. So, if you're looking to get through door1, you gotta hunt down key1 first. And hey, whatever you do, keep your hands off those walls. 6 | 7 | So, the game plan is hitting all the goals, right? But there's a twist: each door needs its matching key. Like, for door1, you gotta find key1 first. And, I can't stress this enough, do not touch the walls. 8 | 9 | Aim to check off all the goals but remember, the keys and doors are paired. You've gotta find key1 before you can unlock door1. One more thing: avoid brushing against the walls at all costs. 10 | 11 | Try to bag all the goals, but keep in mind, you can't just barge into any door. You gotta get the corresponding key first, like key1 for door1. And don't forget: those walls are a no-touch zone. 12 | 13 | You've gotta aim for all the goals, but remember, you need the right key before you can go through any door. For instance, you gotta have key1 if you wanna open door1. Also, never, ever touch the walls. 14 | 15 | Chase after all those goals, but remember, each door has a specific key that unlocks it. You'll need key1 before you can go through door1. And buddy, keep your mitts off the walls, will ya? 16 | 17 | You wanna tick off all the goals, right? But remember, to unlock a door, you need its matching key first. Say, to open door1, you've gotta find key1. And, dude, the walls are not for touching. 18 | 19 | To nail all the goals, you've got to get your hands on the right key before tackling its corresponding door. For instance, door1 ain't gonna budge without key1. And remember, touching those walls is a big no-no. 20 | -------------------------------------------------------------------------------- /experiment_result/myfile.txt: -------------------------------------------------------------------------------- 1 | 0.000000 2 | 0.000000 3 | 0.000000 4 | 0.000000 5 | 0.000000 6 | 0.000000 7 | 0.000000 8 | 0.000000 9 | 0.000000 10 | 0.000000 11 | 0.000000 12 | 0.000000 13 | -0.500000 -1.100000 0.000000 14 | 0.110000 -1.100000 0.610000 15 | 0.110000 -1.090000 0.620000 16 | -0.260000 -1.090000 0.990000 17 | -0.270000 -1.090000 1.000000 18 | -0.280000 -1.090000 1.010000 19 | -0.290000 -1.090000 1.020000 20 | -0.300000 -1.090000 1.030000 21 | -0.310000 -1.090000 1.040000 22 | -0.310000 -1.080000 1.050000 23 | -0.310000 -1.070000 1.060000 24 | -0.310000 -1.060000 1.070000 25 | -0.310000 -1.050000 1.080000 26 | -0.310000 0.910000 3.040000 27 | -0.310000 0.920000 3.050000 28 | 1.150000 1.150000 4.740000 29 | -0.500000 -1.100000 0.000000 30 | 0.110000 -1.100000 0.610000 31 | 0.110000 -1.090000 0.620000 32 | -0.260000 -1.090000 0.990000 33 | -0.270000 -1.090000 1.000000 34 | -0.280000 -1.090000 1.010000 35 | -0.290000 -1.090000 1.020000 36 | -0.300000 -1.090000 1.030000 37 | -0.310000 -1.090000 1.040000 38 | -0.310000 -1.080000 1.050000 39 | -0.310000 -1.070000 1.060000 40 | -0.310000 -1.060000 1.070000 41 | -0.310000 -1.050000 1.080000 42 | -0.310000 0.910000 3.040000 43 | -0.310000 0.920000 3.050000 44 | 1.150000 1.150000 4.740000 45 | 0.000000 46 | 0.000000 47 | 0.000000 48 | 0.000000 49 | 0.000000 50 | 0.000000 51 | 0.000000 52 | 0.000000 53 | 0.000000 54 | 0.000000 55 | 0.000000 56 | 0.000000 57 | 0.000000 58 | 0.000000 59 | 0.000000 60 | -1.350000 -1.100000 0.000000 61 | 0.110000 -1.100000 1.460000 62 | 0.110000 -1.090000 1.470000 63 | -0.310000 0.910000 3.890000 64 | -0.310000 0.920000 3.900000 65 | -0.300000 0.920000 3.910000 66 | -0.290000 0.920000 3.920000 67 | -0.280000 0.920000 3.930000 68 | -0.270000 0.920000 3.940000 69 | -0.260000 0.920000 3.950000 70 | -0.250000 0.920000 3.960000 71 | -0.240000 0.920000 3.970000 72 | -0.240000 0.930000 3.980000 73 | -0.240000 0.940000 3.990000 74 | 1.150000 0.940000 5.380000 75 | 1.150000 1.150000 5.590000 76 | -1.350000 -1.100000 0.000000 77 | 0.110000 -1.100000 1.460000 78 | 0.110000 -1.090000 1.470000 79 | -0.260000 -1.090000 1.840000 80 | -0.270000 -1.090000 1.850000 81 | -0.280000 -1.090000 1.860000 82 | -0.290000 -1.090000 1.870000 83 | -0.300000 -1.090000 1.880000 84 | -0.310000 -1.090000 1.890000 85 | -0.310000 -1.080000 1.900000 86 | -0.310000 -1.070000 1.910000 87 | -0.310000 -1.060000 1.920000 88 | -0.310000 -1.050000 1.930000 89 | -0.310000 0.910000 3.890000 90 | -0.310000 0.920000 3.900000 91 | 1.150000 1.150000 5.590000 92 | -1.350000 -1.100000 0.000000 93 | -1.350000 -1.505000 0.405000 94 | -1.340000 -1.505000 0.415000 95 | -1.340000 -1.515000 0.425000 96 | -0.185000 -1.515000 1.580000 97 | 0.110000 -0.820000 2.570000 98 | 0.110000 -0.810000 2.580000 99 | 0.110000 -0.685000 2.705000 100 | 0.110000 -0.675000 2.715000 101 | -0.615000 -0.615000 3.500000 102 | -0.615000 -0.165000 3.950000 103 | -1.315000 -0.165000 4.650000 104 | -1.315000 0.615000 5.430000 105 | -0.310000 0.910000 6.730000 106 | -0.310000 0.920000 6.740000 107 | 1.150000 1.150000 8.430000 108 | -1.350000 -1.100000 0.000000 109 | 0.110000 -1.100000 1.460000 110 | 0.110000 -0.810000 1.750000 111 | -0.310000 1.130000 4.110000 112 | -0.310000 1.140000 4.120000 113 | 0.300000 1.140000 4.730000 114 | 0.310000 1.140000 4.740000 115 | 0.320000 1.140000 4.750000 116 | 0.330000 1.140000 4.760000 117 | 0.340000 1.140000 4.770000 118 | 0.350000 1.140000 4.780000 119 | 0.360000 1.140000 4.790000 120 | 0.370000 1.140000 4.800000 121 | 0.380000 1.140000 4.810000 122 | 0.380000 1.150000 4.820000 123 | 1.150000 1.150000 5.590000 124 | 0.000000 125 | 0.000000 126 | 0.000000 127 | -1.350000 -1.100000 0.000000 128 | -1.350000 -1.505000 0.405000 129 | -1.340000 -1.505000 0.415000 130 | -1.340000 -1.515000 0.425000 131 | -0.185000 -1.515000 1.580000 132 | 0.110000 -0.820000 2.570000 133 | 0.110000 -0.810000 2.580000 134 | 0.110000 -0.685000 2.705000 135 | 0.110000 -0.675000 2.715000 136 | -0.615000 -0.615000 3.500000 137 | -0.615000 -0.165000 3.950000 138 | -1.315000 -0.165000 4.650000 139 | -1.315000 0.615000 5.430000 140 | -0.310000 0.910000 6.730000 141 | -0.310000 0.920000 6.740000 142 | 1.150000 1.150000 8.430000 143 | -1.350000 -1.100000 0.000000 144 | -1.315000 -1.100000 0.035000 145 | -1.315000 -0.585000 0.550000 146 | -0.685000 -0.585000 1.180000 147 | -0.685000 -0.615000 1.210000 148 | 0.110000 -0.615000 2.005000 149 | 0.110000 -0.810000 2.200000 150 | 0.110000 -0.810000 2.210000 151 | -0.185000 -0.685000 2.630000 152 | -0.615000 -0.615000 3.130000 153 | -0.615000 -0.585000 3.160000 154 | -1.315000 -0.165000 4.280000 155 | -1.315000 0.615000 5.060000 156 | -1.290000 0.910000 5.380000 157 | -0.310000 0.910000 6.360000 158 | 0.000000 1.150000 6.910000 159 | -1.350000 -1.100000 0.000000 160 | -1.350000 -1.505000 0.405000 161 | -1.340000 -1.505000 0.415000 162 | -1.340000 -1.515000 0.425000 163 | -0.185000 -1.515000 1.580000 164 | 0.110000 -0.820000 2.570000 165 | 0.110000 -0.810000 2.580000 166 | 0.110000 -0.685000 2.705000 167 | 0.110000 -0.675000 2.715000 168 | -0.615000 -0.615000 3.500000 169 | -0.615000 -0.165000 3.950000 170 | -1.315000 -0.165000 4.650000 171 | -1.315000 0.615000 5.430000 172 | -0.310000 0.910000 6.730000 173 | -0.310000 0.920000 6.740000 174 | 1.150000 1.150000 8.430000 175 | -1.350000 -1.100000 0.000000 176 | -1.350000 -0.585000 0.515000 177 | -0.685000 -0.585000 1.180000 178 | -0.615000 -0.685000 1.350000 179 | -0.185000 -0.685000 1.780000 180 | 0.110000 -0.810000 2.200000 181 | 0.110000 -0.810000 2.210000 182 | -0.185000 -0.615000 2.700000 183 | -0.685000 -0.615000 3.200000 184 | -0.685000 -0.165000 3.650000 185 | -1.315000 -0.165000 4.280000 186 | -1.315000 0.615000 5.060000 187 | -1.315000 1.150000 5.595000 188 | -0.815000 1.150000 6.095000 189 | -0.805000 1.150000 6.105000 190 | 1.150000 1.150000 8.060000 191 | -1.350000 -1.100000 0.000000 192 | -1.350000 -1.505000 0.405000 193 | -1.340000 -1.505000 0.415000 194 | -1.340000 -1.515000 0.425000 195 | -0.185000 -1.515000 1.580000 196 | 0.110000 -0.820000 2.570000 197 | 0.110000 -0.810000 2.580000 198 | 0.110000 -0.685000 2.705000 199 | 0.110000 -0.675000 2.715000 200 | -0.615000 -0.615000 3.500000 201 | -0.615000 -0.165000 3.950000 202 | -1.315000 -0.165000 4.650000 203 | -1.315000 0.615000 5.430000 204 | -0.310000 0.910000 6.730000 205 | -0.310000 0.920000 6.740000 206 | 1.150000 1.150000 8.430000 207 | -1.350000 -1.100000 0.000000 208 | -1.350000 -1.090000 0.010000 209 | -1.350000 -1.080000 0.020000 210 | -1.350000 -1.070000 0.030000 211 | -1.350000 -1.060000 0.040000 212 | -1.350000 -0.585000 0.515000 213 | -1.340000 -0.585000 0.525000 214 | -1.340000 -0.575000 0.535000 215 | -1.330000 -0.575000 0.545000 216 | -1.320000 -0.575000 0.555000 217 | -1.320000 -0.565000 0.565000 218 | -1.320000 0.910000 2.040000 219 | -0.320000 0.910000 3.040000 220 | -0.310000 0.910000 3.050000 221 | 0.310000 0.915000 3.675000 222 | 1.150000 1.150000 4.750000 223 | 0.000000 224 | 0.000000 225 | 0.000000 226 | -1.350000 -1.100000 0.000000 227 | -1.350000 -1.090000 0.010000 228 | -1.350000 1.060000 2.160000 229 | -1.350000 1.070000 2.170000 230 | -1.350000 1.080000 2.180000 231 | -1.350000 1.090000 2.190000 232 | -1.350000 1.100000 2.200000 233 | -1.350000 1.110000 2.210000 234 | -0.615000 1.110000 2.945000 235 | -0.585000 1.110000 2.975000 236 | -0.585000 1.120000 2.985000 237 | -0.585000 1.130000 2.995000 238 | -0.585000 1.140000 3.005000 239 | -0.585000 1.150000 3.015000 240 | 0.310000 1.150000 3.910000 241 | 1.150000 1.150000 4.750000 242 | -1.350000 -1.100000 0.000000 243 | -1.350000 -1.110000 0.010000 244 | -1.350000 -1.515000 0.415000 245 | -1.340000 -1.515000 0.425000 246 | -1.335000 -1.515000 0.435000 247 | -1.325000 -1.515000 0.445000 248 | -1.315000 -1.515000 0.455000 249 | -0.185000 -1.515000 1.585000 250 | 0.475000 -0.810000 2.950000 251 | 0.485000 -0.810000 2.960000 252 | 1.545000 -0.685000 4.145000 253 | 1.545000 0.915000 5.745000 254 | -0.310000 0.915000 7.600000 255 | -0.310000 0.925000 7.610000 256 | 0.310000 1.150000 8.455000 257 | 1.150000 1.150000 9.295000 258 | 0.000000 259 | 0.000000 260 | 0.000000 261 | -1.350000 -1.100000 0.000000 262 | -0.590000 -1.100000 0.760000 263 | -0.590000 -1.090000 0.770000 264 | -0.800000 -1.090000 0.980000 265 | -0.810000 -1.090000 0.990000 266 | -0.810000 0.060000 2.140000 267 | -0.810000 0.070000 2.150000 268 | -0.810000 0.080000 2.160000 269 | -0.810000 0.090000 2.170000 270 | -0.810000 0.100000 2.180000 271 | -0.810000 0.110000 2.190000 272 | -0.810000 0.120000 2.200000 273 | -0.810000 0.130000 2.210000 274 | -0.810000 0.910000 2.990000 275 | -0.800000 0.910000 3.000000 276 | 1.150000 1.150000 5.190000 277 | -1.350000 -1.100000 0.000000 278 | -0.910000 -1.100000 0.440000 279 | -0.910000 -1.090000 0.450000 280 | 0.110000 -1.090000 1.470000 281 | 0.110000 -1.080000 1.480000 282 | -0.410000 -0.940000 2.140000 283 | -0.410000 -0.930000 2.150000 284 | -0.410000 -0.920000 2.160000 285 | -0.410000 -0.910000 2.170000 286 | -0.410000 0.360000 3.440000 287 | -0.390000 0.360000 3.460000 288 | -0.390000 0.370000 3.470000 289 | -0.810000 0.370000 3.890000 290 | -0.810000 0.380000 3.900000 291 | -0.810000 0.390000 3.910000 292 | -0.810000 0.910000 4.430000 293 | -0.800000 0.910000 4.440000 294 | -0.790000 0.910000 4.450000 295 | 1.130000 0.910000 6.370000 296 | 1.140000 0.910000 6.380000 297 | 1.140000 0.690000 6.600000 298 | 1.150000 0.690000 6.610000 299 | 1.150000 0.910000 6.830000 300 | 1.150000 0.920000 6.840000 301 | 1.150000 0.930000 6.850000 302 | 1.150000 1.150000 7.070000 303 | -1.350000 -1.100000 0.000000 304 | -0.910000 -1.100000 0.440000 305 | -0.910000 -1.090000 0.450000 306 | -0.410000 -1.090000 0.950000 307 | -0.410000 -1.080000 0.960000 308 | -0.410000 -1.070000 0.970000 309 | -0.410000 -1.060000 0.980000 310 | -0.390000 -0.390000 1.670000 311 | -0.380000 -0.390000 1.680000 312 | -0.370000 -0.390000 1.690000 313 | 0.110000 -0.810000 2.590000 314 | 0.110000 -0.810000 2.600000 315 | -0.810000 -0.810000 3.520000 316 | -0.810000 -0.800000 3.530000 317 | -0.810000 -0.790000 3.540000 318 | -0.810000 -0.780000 3.550000 319 | -0.810000 0.380000 4.710000 320 | -0.810000 0.390000 4.720000 321 | -0.800000 0.390000 4.730000 322 | -0.800000 0.910000 5.250000 323 | -0.790000 0.910000 5.260000 324 | -0.780000 0.910000 5.270000 325 | 1.130000 0.690000 7.400000 326 | 1.140000 0.690000 7.410000 327 | 1.140000 1.150000 7.870000 328 | 1.150000 1.150000 7.880000 329 | -1.350000 -1.100000 0.000000 330 | -1.110000 -0.910000 0.430000 331 | -1.100000 -0.910000 0.440000 332 | -1.090000 -0.910000 0.450000 333 | -0.910000 -0.910000 0.630000 334 | -0.420000 -0.910000 1.120000 335 | -0.410000 -0.910000 1.130000 336 | 0.110000 -0.910000 1.650000 337 | 0.110000 -0.900000 1.660000 338 | 0.110000 -0.390000 2.170000 339 | 0.110000 0.360000 2.920000 340 | -0.390000 0.360000 3.420000 341 | -0.390000 0.370000 3.430000 342 | -0.390000 0.380000 3.440000 343 | -0.810000 0.380000 3.860000 344 | -0.810000 0.390000 3.870000 345 | -0.810000 0.900000 4.380000 346 | -0.810000 0.910000 4.390000 347 | -0.800000 0.910000 4.400000 348 | -0.800000 0.690000 4.620000 349 | 0.710000 0.690000 6.130000 350 | 0.720000 0.690000 6.140000 351 | 0.720000 1.140000 6.590000 352 | 0.720000 1.150000 6.600000 353 | 1.140000 1.150000 7.020000 354 | 1.150000 1.150000 7.030000 355 | -1.350000 -1.100000 0.000000 356 | -1.350000 -1.090000 0.010000 357 | -1.350000 -0.920000 0.180000 358 | -1.090000 -0.920000 0.440000 359 | -0.910000 -0.920000 0.620000 360 | -0.420000 -0.920000 1.110000 361 | -0.410000 -0.920000 1.120000 362 | -0.410000 -0.910000 1.130000 363 | 0.110000 -0.910000 1.650000 364 | 0.110000 -0.810000 1.750000 365 | 0.110000 -0.430000 2.130000 366 | 0.110000 -0.420000 2.140000 367 | 0.110000 -0.410000 2.150000 368 | 0.110000 -0.400000 2.160000 369 | 0.110000 -0.390000 2.170000 370 | 0.100000 -0.390000 2.180000 371 | 0.090000 -0.390000 2.190000 372 | 0.080000 -0.390000 2.200000 373 | 0.070000 -0.390000 2.210000 374 | 0.060000 -0.390000 2.220000 375 | 0.050000 -0.390000 2.230000 376 | 0.040000 -0.390000 2.240000 377 | 0.030000 -0.390000 2.250000 378 | -0.380000 -0.390000 2.660000 379 | -0.390000 -0.390000 2.670000 380 | -0.810000 -0.390000 3.090000 381 | -0.810000 -0.380000 3.100000 382 | -0.810000 0.060000 3.540000 383 | -0.810000 0.390000 3.870000 384 | -0.810000 0.910000 4.390000 385 | -0.310000 0.910000 4.890000 386 | 0.710000 0.690000 6.130000 387 | 0.720000 0.690000 6.140000 388 | 0.730000 0.690000 6.150000 389 | 0.730000 1.150000 6.610000 390 | 1.150000 1.150000 7.030000 391 | -1.350000 -1.100000 0.000000 392 | -0.910000 -1.100000 0.440000 393 | -0.910000 -1.090000 0.450000 394 | -0.410000 -1.090000 0.950000 395 | -0.410000 -1.080000 0.960000 396 | -0.410000 -1.070000 0.970000 397 | -0.410000 -1.060000 0.980000 398 | -0.390000 -0.390000 1.670000 399 | -0.380000 -0.390000 1.680000 400 | -0.370000 -0.390000 1.690000 401 | 0.110000 -0.810000 2.590000 402 | 0.110000 -0.810000 2.600000 403 | -0.810000 -0.810000 3.520000 404 | -0.810000 -0.800000 3.530000 405 | -0.810000 -0.790000 3.540000 406 | -0.810000 -0.780000 3.550000 407 | -0.810000 0.380000 4.710000 408 | -0.810000 0.390000 4.720000 409 | -0.800000 0.390000 4.730000 410 | -0.800000 0.910000 5.250000 411 | -0.790000 0.910000 5.260000 412 | -0.780000 0.910000 5.270000 413 | 1.130000 0.690000 7.400000 414 | 1.140000 0.690000 7.410000 415 | 1.140000 1.150000 7.870000 416 | 1.150000 1.150000 7.880000 417 | -1.371024 -0.102864 0.000000 418 | -1.371024 0.060000 0.162864 419 | -1.090000 0.060000 0.443888 420 | -1.080000 0.060000 0.453888 421 | -1.080000 -0.810000 1.323888 422 | -1.070000 -0.810000 1.333888 423 | -1.060000 -0.810000 1.343888 424 | -1.050000 -0.810000 1.353888 425 | -1.040000 -0.810000 1.363888 426 | -0.440000 -0.910000 2.063888 427 | -0.430000 -0.910000 2.073888 428 | -0.420000 -0.910000 2.083888 429 | -0.410000 -0.910000 2.093888 430 | 0.110000 -0.810000 2.713888 431 | 0.710000 -0.810000 3.313888 432 | 0.710000 -0.800000 3.323888 433 | 0.710000 0.310000 4.433888 434 | 0.710000 0.320000 4.443888 435 | 0.390000 0.320000 4.763888 436 | 0.310000 0.320000 4.843888 437 | 0.310000 0.330000 4.853888 438 | 0.310000 0.910000 5.433888 439 | 0.310000 0.920000 5.443888 440 | -0.310000 1.298267 6.442155 441 | -0.310000 1.308267 6.452155 442 | -0.045226 1.308267 6.716929 443 | -0.626873 -0.261318 0.000000 444 | -0.590000 -0.910000 0.685555 445 | -0.410000 -0.910000 0.865555 446 | 0.110000 -0.910000 1.385555 447 | 0.110000 -0.900000 1.395555 448 | -0.910000 -0.900000 2.415555 449 | -0.910000 -0.890000 2.425555 450 | 0.390000 -0.390000 4.225555 451 | 0.390000 -0.380000 4.235555 452 | 0.710000 0.370000 5.305555 453 | 0.710000 0.380000 5.315555 454 | -0.810000 0.380000 6.835555 455 | -0.810000 0.390000 6.845555 456 | -0.810000 0.910000 7.365555 457 | -0.800000 0.910000 7.375555 458 | 0.310000 0.910000 8.485555 459 | 0.310000 1.202934 8.778490 460 | -0.097635 1.202934 9.186125 461 | -0.107635 1.202934 9.196125 462 | -0.117635 1.202934 9.206125 463 | -0.127635 1.202934 9.216125 464 | 0.000000 465 | 0.000000 466 | 0.000000 467 | -0.772017 -0.279814 0.000000 468 | -0.910000 -0.810000 0.668169 469 | -0.910000 -0.910000 0.768169 470 | -0.420000 -0.910000 1.258169 471 | -0.410000 -0.910000 1.268169 472 | 0.110000 -0.810000 1.888169 473 | 0.380000 -0.810000 2.158169 474 | 0.380000 0.370000 3.338169 475 | 0.390000 0.370000 3.348169 476 | 0.710000 0.370000 3.668169 477 | 0.710000 0.380000 3.678169 478 | -0.810000 0.380000 5.198169 479 | -0.810000 0.390000 5.208169 480 | -0.310000 0.910000 6.228169 481 | -0.310000 0.920000 6.238169 482 | 0.310000 0.920000 6.858169 483 | 0.310000 0.930000 6.868169 484 | 0.034058 0.930000 7.144111 485 | 0.034058 0.940000 7.154111 486 | 0.034058 1.212841 7.426953 487 | 0.034058 1.222841 7.436953 488 | 0.000000 489 | 0.000000 490 | 0.000000 491 | 0.000000 492 | 0.000000 493 | 0.000000 494 | -0.899909 -0.357500 0.000000 495 | -0.909909 -0.357500 0.010000 496 | -1.315000 -0.357500 0.415091 497 | -1.315000 -0.245000 0.527591 498 | -1.315000 -0.235000 0.537591 499 | -1.315000 -0.225000 0.547591 500 | -1.315000 -0.215000 0.557591 501 | -1.315000 -0.205000 0.567591 502 | -1.315000 -0.195000 0.577591 503 | -1.315000 -0.185000 0.587591 504 | -1.315000 -0.175000 0.597591 505 | -1.315000 -0.165000 0.607591 506 | -1.315000 -0.155000 0.617591 507 | -1.315000 -0.145000 0.627591 508 | -1.315000 0.615000 1.387591 509 | -1.305000 0.615000 1.397591 510 | -1.290000 0.910000 1.707591 511 | -1.280000 0.910000 1.717591 512 | 0.310000 0.910000 3.307591 513 | 0.310000 1.320000 3.717591 514 | 0.140621 1.328914 3.895883 515 | 0.000000 516 | 0.000000 517 | 0.000000 518 | -1.070764 -0.562708 0.000000 519 | -1.070764 -0.810000 0.247292 520 | -1.080764 -0.810000 0.257292 521 | -1.315000 -0.810000 0.491527 522 | -1.315000 0.615000 1.916527 523 | -0.685000 0.615000 2.546527 524 | -0.675000 0.615000 2.556527 525 | -0.665000 0.615000 2.566527 526 | -0.655000 0.615000 2.576527 527 | -0.645000 0.615000 2.586527 528 | -0.635000 0.615000 2.596527 529 | -0.625000 0.615000 2.606527 530 | -0.615000 0.615000 2.616527 531 | -0.605000 0.615000 2.626527 532 | -0.595000 0.615000 2.636527 533 | -0.585000 0.615000 2.646527 534 | 0.300000 0.615000 3.531527 535 | 0.310000 0.615000 3.541527 536 | 0.310000 0.910000 3.836527 537 | 0.310000 1.320000 4.246527 538 | -0.070537 1.332161 4.639225 539 | -1.350000 -1.100000 0.000000 540 | -1.340000 -1.100000 0.010000 541 | -1.330000 -1.100000 0.020000 542 | -1.320000 -1.100000 0.030000 543 | -1.310000 -1.100000 0.040000 544 | -1.300000 -1.100000 0.050000 545 | -1.290000 -1.100000 0.060000 546 | -1.090000 -1.100000 0.260000 547 | -1.080000 -1.100000 0.270000 548 | 0.110000 -1.100000 1.460000 549 | 0.120000 -1.100000 1.470000 550 | 0.130000 -1.100000 1.480000 551 | 0.130000 -1.090000 1.490000 552 | 1.090000 0.310000 3.850000 553 | 1.100000 0.310000 3.860000 554 | 1.110000 0.310000 3.870000 555 | 1.120000 0.310000 3.880000 556 | 1.130000 0.310000 3.890000 557 | 1.140000 0.310000 3.900000 558 | 1.150000 0.310000 3.910000 559 | 1.150000 1.150000 4.750000 560 | -1.350000 -1.100000 0.000000 561 | -1.340000 -1.100000 0.010000 562 | -1.330000 -1.100000 0.020000 563 | -1.320000 -1.100000 0.030000 564 | -1.310000 -1.100000 0.040000 565 | -1.300000 -1.100000 0.050000 566 | -1.290000 -1.100000 0.060000 567 | -1.090000 -1.100000 0.260000 568 | -1.080000 -1.100000 0.270000 569 | 0.110000 -1.100000 1.460000 570 | 0.120000 -1.100000 1.470000 571 | 0.130000 -1.100000 1.480000 572 | 0.130000 -1.090000 1.490000 573 | 1.090000 0.310000 3.850000 574 | 1.100000 0.310000 3.860000 575 | 1.110000 0.310000 3.870000 576 | 1.120000 0.310000 3.880000 577 | 1.130000 0.310000 3.890000 578 | 1.140000 0.310000 3.900000 579 | 1.150000 0.310000 3.910000 580 | 1.150000 1.150000 4.750000 581 | -1.350000 -1.100000 0.000000 582 | 4.560000 0.560000 7.570000 583 | 4.570000 0.560000 7.580000 584 | 4.580000 0.560000 7.590000 585 | 6.560000 0.560000 9.570000 586 | 6.560000 0.570000 9.580000 587 | 6.550000 0.570000 9.590000 588 | 6.540000 0.570000 9.600000 589 | 2.620000 0.570000 13.520000 590 | 2.610000 0.570000 13.530000 591 | 2.600000 0.570000 13.540000 592 | 2.590000 0.570000 13.550000 593 | 2.580000 0.570000 13.560000 594 | 2.570000 0.570000 13.570000 595 | 2.570000 0.580000 13.580000 596 | 2.570000 0.590000 13.590000 597 | 2.570000 2.540000 15.540000 598 | 2.570000 2.550000 15.550000 599 | 2.570000 2.560000 15.560000 600 | 2.560000 2.560000 15.570000 601 | 1.150000 1.150000 18.390000 602 | -1.350000 -1.100000 0.000000 603 | -1.340000 -1.100000 0.010000 604 | 1.380000 6.610000 10.440000 605 | 1.390000 6.610000 10.450000 606 | 2.560000 6.610000 11.620000 607 | 2.560000 5.440000 12.790000 608 | 2.560000 5.430000 12.800000 609 | 2.560000 2.600000 15.630000 610 | 2.560000 2.590000 15.640000 611 | 2.560000 2.580000 15.650000 612 | 2.560000 2.570000 15.660000 613 | 2.570000 2.570000 15.670000 614 | 2.570000 2.560000 15.680000 615 | 2.580000 2.560000 15.690000 616 | 2.590000 2.560000 15.700000 617 | 6.560000 1.160000 21.070000 618 | 6.560000 1.150000 21.080000 619 | 5.440000 1.150000 22.200000 620 | 5.430000 1.150000 22.210000 621 | 1.440000 1.150000 26.200000 622 | 1.150000 1.150000 26.490000 623 | 5.000000 5.000000 0.000000 624 | 5.000000 4.990000 0.010000 625 | 6.560000 1.440000 5.120000 626 | 6.560000 1.440000 5.130000 627 | 5.460000 1.440000 6.230000 628 | 5.450000 1.440000 6.240000 629 | 5.440000 1.440000 6.250000 630 | 5.430000 1.440000 6.260000 631 | 5.420000 1.440000 6.270000 632 | 1.440000 1.440000 10.250000 633 | 1.440000 1.440000 10.260000 634 | 2.560000 1.440000 11.380000 635 | 2.560000 2.550000 12.490000 636 | 2.560000 2.560000 12.500000 637 | 2.560000 2.570000 12.510000 638 | 2.560000 4.550000 14.490000 639 | 2.560000 4.560000 14.500000 640 | 2.560000 5.440000 15.380000 641 | 1.390000 6.610000 17.720000 642 | 1.390000 6.620000 17.730000 643 | 3.000000 7.000000 19.720000 644 | 0.000000 645 | 0.000000 646 | 0.000000 647 | 5.000000 5.000000 0.000000 648 | 5.000000 4.990000 0.010000 649 | 6.560000 1.440000 5.120000 650 | 6.560000 1.440000 5.130000 651 | 5.460000 1.440000 6.230000 652 | 5.450000 1.440000 6.240000 653 | 5.440000 1.440000 6.250000 654 | 5.430000 1.440000 6.260000 655 | 5.420000 1.440000 6.270000 656 | 1.440000 1.440000 10.250000 657 | 1.440000 1.440000 10.260000 658 | 2.560000 1.440000 11.380000 659 | 2.560000 2.550000 12.490000 660 | 2.560000 2.560000 12.500000 661 | 2.560000 2.570000 12.510000 662 | 2.560000 4.550000 14.490000 663 | 2.560000 4.560000 14.500000 664 | 2.560000 5.440000 15.380000 665 | 1.390000 6.610000 17.720000 666 | 1.390000 6.620000 17.730000 667 | 3.000000 7.000000 19.720000 668 | 5.000000 5.000000 0.000000 669 | 5.000000 4.990000 0.010000 670 | 6.560000 1.450000 5.110000 671 | 6.560000 1.440000 5.120000 672 | 6.560000 1.440000 5.130000 673 | 6.550000 1.440000 5.140000 674 | 6.540000 1.440000 5.150000 675 | 5.440000 1.440000 6.250000 676 | 5.430000 1.440000 6.260000 677 | 1.440000 1.440000 10.250000 678 | 1.440000 1.440000 10.260000 679 | 1.440000 3.410000 12.230000 680 | 3.000000 3.410000 13.790000 681 | 3.000000 3.420000 13.800000 682 | 3.000000 3.430000 13.810000 683 | 3.000000 3.440000 13.820000 684 | 3.000000 3.450000 13.830000 685 | 3.000000 5.430000 15.810000 686 | 3.000000 5.440000 15.820000 687 | 3.000000 6.990000 17.370000 688 | 3.000000 7.000000 17.380000 689 | 5.000000 5.000000 0.000000 690 | 5.000000 1.440000 3.560000 691 | 5.440000 1.440000 4.000000 692 | 5.450000 1.440000 4.010000 693 | 6.560000 1.440000 5.120000 694 | 6.560000 1.430000 5.130000 695 | 6.550000 1.430000 5.140000 696 | 6.540000 1.430000 5.150000 697 | 6.530000 1.430000 5.160000 698 | 1.440000 1.430000 10.250000 699 | 1.440000 1.440000 10.260000 700 | 2.960000 1.440000 11.780000 701 | 2.960000 1.450000 11.790000 702 | 2.960000 2.560000 12.900000 703 | 2.960000 2.570000 12.910000 704 | 2.960000 4.560000 14.900000 705 | 2.970000 4.560000 14.910000 706 | 2.980000 4.560000 14.920000 707 | 2.990000 4.560000 14.930000 708 | 3.000000 4.560000 14.940000 709 | 3.000000 7.000000 17.380000 710 | 0.000000 711 | 0.000000 712 | 0.000000 713 | 0.000000 714 | 0.000000 715 | 0.000000 716 | 5.000000 5.000000 0.000000 717 | 5.000000 5.010000 0.010000 718 | 5.000000 5.115000 0.115000 719 | 5.000000 5.125000 0.125000 720 | 5.000000 5.135000 0.135000 721 | 5.000000 5.145000 0.145000 722 | 5.000000 5.155000 0.155000 723 | 5.000000 5.165000 0.165000 724 | 5.000000 5.175000 0.175000 725 | 5.000000 5.185000 0.185000 726 | 5.000000 5.195000 0.195000 727 | 5.010000 5.195000 0.205000 728 | 5.020000 5.195000 0.215000 729 | 5.030000 5.195000 0.225000 730 | 5.040000 5.195000 0.235000 731 | 5.040000 5.785000 0.825000 732 | 5.050000 5.785000 0.835000 733 | 5.060000 5.785000 0.845000 734 | 7.115000 5.785000 2.900000 735 | 7.115000 6.215000 3.330000 736 | 3.000000 7.000000 8.230000 737 | 5.000000 5.000000 0.000000 738 | 5.000000 3.785000 1.215000 739 | 3.785000 3.785000 2.430000 740 | 3.775000 3.785000 2.440000 741 | 2.590000 2.560000 4.850000 742 | 2.580000 2.560000 4.860000 743 | 2.570000 2.560000 4.870000 744 | 2.560000 2.560000 4.880000 745 | 2.215000 0.935000 6.850000 746 | 2.215000 0.925000 6.860000 747 | 2.215000 0.915000 6.870000 748 | 2.215000 0.905000 6.880000 749 | 2.215000 0.895000 6.890000 750 | 2.215000 0.885000 6.900000 751 | 1.440000 0.885000 7.675000 752 | 1.440000 0.885000 7.685000 753 | 4.215000 0.885000 10.460000 754 | 4.215000 5.115000 14.690000 755 | 7.115000 5.115000 17.590000 756 | 7.115000 7.000000 19.475000 757 | 3.000000 7.000000 23.590000 758 | 0.000000 759 | 0.000000 760 | 0.000000 761 | 5.000000 5.000000 0.000000 762 | 4.215000 5.000000 0.785000 763 | 4.215000 2.620000 3.165000 764 | 4.215000 2.610000 3.175000 765 | 4.215000 2.600000 3.185000 766 | 4.215000 2.590000 3.195000 767 | 4.215000 2.580000 3.205000 768 | 4.215000 2.570000 3.215000 769 | 4.215000 2.560000 3.225000 770 | 3.440000 2.560000 4.000000 771 | 2.560000 2.560000 4.880000 772 | 2.215000 0.885000 6.900000 773 | 1.440000 0.885000 7.675000 774 | 1.440000 0.885000 7.685000 775 | 2.215000 0.885000 8.460000 776 | 4.560000 0.885000 10.805000 777 | 4.570000 0.885000 10.815000 778 | 4.570000 5.115000 15.045000 779 | 7.115000 5.785000 18.260000 780 | 7.115000 6.215000 18.690000 781 | 3.000000 7.000000 23.590000 782 | 5.000000 5.000000 0.000000 783 | 5.000000 3.785000 1.215000 784 | 3.440000 2.560000 4.000000 785 | 3.430000 2.560000 4.010000 786 | 3.430000 2.550000 4.020000 787 | 3.430000 1.240981 5.329019 788 | 3.430000 1.230981 5.339019 789 | 3.430000 0.885000 5.685000 790 | 1.440000 0.885000 7.675000 791 | 1.440000 1.440000 8.230000 792 | 1.440000 4.215000 11.005000 793 | 2.560000 4.560000 12.470000 794 | 2.560000 4.560000 12.480000 795 | 1.785000 4.215000 13.600000 796 | 1.785000 2.115000 15.700000 797 | 1.785000 0.885000 16.930000 798 | 4.105000 0.885000 19.250000 799 | 4.115000 0.885000 19.260000 800 | 4.215000 0.885000 19.360000 801 | 4.215000 0.895000 19.370000 802 | 4.560000 0.895000 19.715000 803 | 4.570000 0.895000 19.725000 804 | 4.570000 5.115000 23.945000 805 | 6.560000 5.115000 25.935000 806 | 6.560000 1.440000 29.610000 807 | 7.115000 1.440000 30.165000 808 | 7.115000 4.282500 33.007500 809 | 7.115000 6.215000 34.940000 810 | 1.390000 6.610000 41.060000 811 | 1.390000 7.000000 41.450000 812 | 3.000000 7.000000 43.060000 813 | 5.000000 5.000000 0.000000 814 | 5.000000 1.440000 3.560000 815 | 5.010000 1.440000 3.570000 816 | 6.560000 1.440000 5.120000 817 | 6.560000 1.440000 5.130000 818 | 1.530000 1.440000 10.160000 819 | 1.520000 1.440000 10.170000 820 | 1.510000 1.440000 10.180000 821 | 1.500000 1.440000 10.190000 822 | 1.490000 1.440000 10.200000 823 | 1.480000 1.440000 10.210000 824 | 1.470000 1.440000 10.220000 825 | 1.460000 1.440000 10.230000 826 | 1.450000 1.440000 10.240000 827 | 1.440000 1.440000 10.250000 828 | 1.440000 1.440000 10.260000 829 | 1.450000 1.440000 10.270000 830 | 1.460000 1.440000 10.280000 831 | 2.560000 1.440000 11.380000 832 | 2.560000 1.450000 11.390000 833 | 2.560000 1.460000 11.400000 834 | 2.560000 2.560000 12.500000 835 | 2.560000 2.570000 12.510000 836 | 2.560000 2.580000 12.520000 837 | 2.560000 5.430000 15.370000 838 | 2.560000 5.440000 15.380000 839 | 1.390000 6.980000 18.090000 840 | 1.390000 6.990000 18.100000 841 | 1.390000 7.000000 18.110000 842 | 2.990000 7.000000 19.710000 843 | 3.000000 7.000000 19.720000 844 | 5.000000 5.000000 0.000000 845 | 5.000000 3.785000 1.215000 846 | 3.440000 3.440000 3.120000 847 | 2.560000 2.560000 4.880000 848 | 2.225000 0.885000 6.890000 849 | 2.215000 0.885000 6.900000 850 | 1.440000 0.885000 7.675000 851 | 1.440000 1.440000 8.230000 852 | 1.785000 4.215000 11.350000 853 | 2.560000 4.560000 12.470000 854 | 2.560000 4.560000 12.480000 855 | 1.785000 4.215000 13.600000 856 | 1.785000 0.885000 16.930000 857 | 2.215000 0.885000 17.360000 858 | 4.560000 0.885000 19.705000 859 | 4.560000 0.895000 19.715000 860 | 4.560000 0.905000 19.725000 861 | 4.560000 4.115000 22.935000 862 | 4.570000 4.115000 22.945000 863 | 4.580000 4.115000 22.955000 864 | 4.580000 5.115000 23.955000 865 | 6.215000 5.115000 25.590000 866 | 6.215000 1.440000 29.265000 867 | 7.105000 1.440000 30.155000 868 | 7.115000 1.440000 30.165000 869 | 7.115000 6.215000 34.940000 870 | 5.785000 6.610000 36.665000 871 | 1.390000 6.610000 41.060000 872 | 1.390000 6.620000 41.070000 873 | 1.400000 6.620000 41.080000 874 | 3.000000 7.000000 43.060000 875 | 5.000000 5.000000 0.000000 876 | 5.000000 3.785000 1.215000 877 | 3.440000 3.440000 3.120000 878 | 2.560000 2.560000 4.880000 879 | 2.225000 0.885000 6.890000 880 | 2.215000 0.885000 6.900000 881 | 1.440000 0.885000 7.675000 882 | 1.440000 1.440000 8.230000 883 | 1.785000 4.215000 11.350000 884 | 2.560000 4.560000 12.470000 885 | 2.560000 4.560000 12.480000 886 | 1.785000 4.215000 13.600000 887 | 1.785000 0.885000 16.930000 888 | 2.215000 0.885000 17.360000 889 | 4.560000 0.885000 19.705000 890 | 4.560000 0.895000 19.715000 891 | 4.560000 0.905000 19.725000 892 | 4.560000 4.115000 22.935000 893 | 4.570000 4.115000 22.945000 894 | 4.580000 4.115000 22.955000 895 | 4.580000 5.115000 23.955000 896 | 6.215000 5.115000 25.590000 897 | 6.215000 1.440000 29.265000 898 | 7.105000 1.440000 30.155000 899 | 7.115000 1.440000 30.165000 900 | 7.115000 6.215000 34.940000 901 | 5.785000 6.610000 36.665000 902 | 1.390000 6.610000 41.060000 903 | 1.390000 6.620000 41.070000 904 | 1.400000 6.620000 41.080000 905 | 3.000000 7.000000 43.060000 906 | 5.000000 5.000000 0.000000 907 | 5.000000 1.440000 3.560000 908 | 4.560000 0.885000 4.555000 909 | 1.440000 0.885000 7.675000 910 | 1.440000 0.895000 7.685000 911 | 1.440000 0.905000 7.695000 912 | 1.440000 0.915000 7.705000 913 | 1.440000 0.925000 7.715000 914 | 1.440000 4.215000 11.005000 915 | 2.560000 4.560000 12.470000 916 | 2.560000 4.560000 12.480000 917 | 1.785000 4.560000 13.255000 918 | 1.785000 0.885000 16.930000 919 | 2.215000 0.885000 17.360000 920 | 2.215000 0.895000 17.370000 921 | 2.560000 2.560000 19.380000 922 | 2.570000 2.560000 19.390000 923 | 4.215000 2.560000 21.035000 924 | 4.215000 5.115000 23.590000 925 | 6.215000 5.115000 25.590000 926 | 6.215000 5.105000 25.600000 927 | 6.560000 1.440000 29.610000 928 | 6.570000 1.440000 29.620000 929 | 6.580000 1.440000 29.630000 930 | 6.590000 1.440000 29.640000 931 | 6.600000 1.440000 29.650000 932 | 7.115000 1.440000 30.165000 933 | 7.115000 6.215000 34.940000 934 | 1.390000 6.610000 41.060000 935 | 1.390000 6.620000 41.070000 936 | 3.000000 7.000000 43.060000 937 | 5.000000 5.000000 0.000000 938 | 5.000000 3.785000 1.215000 939 | 3.440000 3.440000 3.120000 940 | 2.560000 2.560000 4.880000 941 | 2.225000 0.885000 6.890000 942 | 2.215000 0.885000 6.900000 943 | 1.440000 0.885000 7.675000 944 | 1.440000 1.440000 8.230000 945 | 1.785000 4.215000 11.350000 946 | 2.560000 4.560000 12.470000 947 | 2.560000 4.560000 12.480000 948 | 1.785000 4.215000 13.600000 949 | 1.785000 0.885000 16.930000 950 | 2.215000 0.885000 17.360000 951 | 4.560000 0.885000 19.705000 952 | 4.560000 0.895000 19.715000 953 | 4.560000 0.905000 19.725000 954 | 4.560000 4.115000 22.935000 955 | 4.570000 4.115000 22.945000 956 | 4.580000 4.115000 22.955000 957 | 4.580000 5.115000 23.955000 958 | 6.215000 5.115000 25.590000 959 | 6.215000 1.440000 29.265000 960 | 7.105000 1.440000 30.155000 961 | 7.115000 1.440000 30.165000 962 | 7.115000 6.215000 34.940000 963 | 5.785000 6.610000 36.665000 964 | 1.390000 6.610000 41.060000 965 | 1.390000 6.620000 41.070000 966 | 1.400000 6.620000 41.080000 967 | 3.000000 7.000000 43.060000 968 | 5.000000 5.000000 0.000000 969 | 4.560000 5.000000 0.440000 970 | 4.560000 1.440000 4.000000 971 | 4.560000 0.885000 4.555000 972 | 4.215000 0.885000 4.900000 973 | 1.440000 0.885000 7.675000 974 | 1.440000 0.895000 7.685000 975 | 1.440000 4.215000 11.005000 976 | 2.215000 4.215000 11.780000 977 | 2.560000 4.560000 12.470000 978 | 2.560000 4.560000 12.480000 979 | 1.785000 4.215000 13.600000 980 | 1.785000 3.785000 14.030000 981 | 1.785000 0.885000 16.930000 982 | 2.560000 0.885000 17.705000 983 | 2.560000 2.560000 19.380000 984 | 2.560000 2.570000 19.390000 985 | 2.560000 3.785000 20.605000 986 | 5.785000 3.785000 23.830000 987 | 5.785000 5.115000 25.160000 988 | 6.215000 5.115000 25.590000 989 | 6.215000 5.105000 25.600000 990 | 6.560000 1.440000 29.610000 991 | 7.115000 1.440000 30.165000 992 | 7.115000 1.450000 30.175000 993 | 7.115000 6.215000 34.940000 994 | 7.105000 6.215000 34.950000 995 | 7.105000 6.225000 34.960000 996 | 3.010000 6.225000 39.055000 997 | 3.000000 6.225000 39.065000 998 | 3.000000 7.000000 39.840000 999 | 5.000000 5.000000 0.000000 1000 | 5.000000 3.785000 1.215000 1001 | 3.440000 3.440000 3.120000 1002 | 2.560000 3.440000 4.000000 1003 | 2.225000 3.440000 4.335000 1004 | 2.215000 0.885000 6.900000 1005 | 1.440000 0.885000 7.675000 1006 | 1.440000 1.440000 8.230000 1007 | 1.440000 4.215000 11.005000 1008 | 2.560000 4.560000 12.470000 1009 | 2.560000 4.560000 12.480000 1010 | 1.785000 4.215000 13.600000 1011 | 1.785000 0.885000 16.930000 1012 | 2.215000 0.885000 17.360000 1013 | 4.560000 0.885000 19.705000 1014 | 4.560000 0.895000 19.715000 1015 | 4.560000 0.905000 19.725000 1016 | 4.560000 4.115000 22.935000 1017 | 4.570000 4.115000 22.945000 1018 | 4.580000 4.115000 22.955000 1019 | 4.580000 5.115000 23.955000 1020 | 6.215000 5.115000 25.590000 1021 | 6.215000 1.440000 29.265000 1022 | 7.105000 1.440000 30.155000 1023 | 7.115000 1.440000 30.165000 1024 | 7.115000 6.215000 34.940000 1025 | 5.785000 6.610000 36.665000 1026 | 1.390000 6.610000 41.060000 1027 | 1.390000 6.620000 41.070000 1028 | 3.000000 6.620000 42.680000 1029 | 3.000000 7.000000 43.060000 1030 | 0.000000 1031 | 0.000000 1032 | 0.000000 1033 | 5.000000 5.000000 0.000000 1034 | 5.000000 3.785000 1.215000 1035 | 3.440000 2.560000 4.000000 1036 | 3.430000 2.560000 4.010000 1037 | 3.430000 2.550000 4.020000 1038 | 3.430000 1.240981 5.329019 1039 | 3.430000 1.230981 5.339019 1040 | 3.430000 0.885000 5.685000 1041 | 1.440000 0.885000 7.675000 1042 | 1.440000 1.440000 8.230000 1043 | 1.440000 4.215000 11.005000 1044 | 2.560000 4.560000 12.470000 1045 | 2.560000 4.560000 12.480000 1046 | 1.785000 4.215000 13.600000 1047 | 1.785000 2.115000 15.700000 1048 | 1.785000 0.885000 16.930000 1049 | 4.105000 0.885000 19.250000 1050 | 4.115000 0.885000 19.260000 1051 | 4.215000 0.885000 19.360000 1052 | 4.215000 0.895000 19.370000 1053 | 4.560000 0.895000 19.715000 1054 | 4.570000 0.895000 19.725000 1055 | 4.570000 5.115000 23.945000 1056 | 6.560000 5.115000 25.935000 1057 | 6.560000 1.440000 29.610000 1058 | 7.115000 1.440000 30.165000 1059 | 7.115000 4.282500 33.007500 1060 | 7.115000 6.215000 34.940000 1061 | 1.390000 6.610000 41.060000 1062 | 1.390000 7.000000 41.450000 1063 | 3.000000 7.000000 43.060000 1064 | 5.000000 5.000000 0.000000 1065 | 4.560000 1.440000 4.000000 1066 | 4.560000 1.115000 4.325000 1067 | 2.225000 1.115000 6.660000 1068 | 2.225000 0.895000 6.880000 1069 | 2.225000 0.885000 6.890000 1070 | 2.215000 0.885000 6.900000 1071 | 1.460000 0.885000 7.655000 1072 | 1.450000 0.885000 7.665000 1073 | 1.440000 0.885000 7.675000 1074 | 1.440000 1.440000 8.230000 1075 | 1.450000 1.440000 8.240000 1076 | 1.450000 4.215000 11.015000 1077 | 2.560000 4.560000 12.470000 1078 | 2.560000 4.560000 12.480000 1079 | 1.785000 4.560000 13.255000 1080 | 1.785000 0.885000 16.930000 1081 | 2.560000 0.885000 17.705000 1082 | 2.560000 2.560000 19.380000 1083 | 2.570000 2.560000 19.390000 1084 | 4.215000 2.560000 21.035000 1085 | 5.785000 5.115000 25.160000 1086 | 6.215000 5.115000 25.590000 1087 | 6.560000 1.440000 29.610000 1088 | 7.115000 1.440000 30.165000 1089 | 7.115000 6.215000 34.940000 1090 | 1.390000 6.610000 41.060000 1091 | 1.390000 6.620000 41.070000 1092 | 1.400000 6.620000 41.080000 1093 | 3.000000 6.620000 42.680000 1094 | 3.000000 7.000000 43.060000 1095 | 5.000000 5.000000 0.000000 1096 | 4.560000 1.440000 4.000000 1097 | 4.560000 1.115000 4.325000 1098 | 2.225000 1.115000 6.660000 1099 | 2.225000 0.895000 6.880000 1100 | 2.225000 0.885000 6.890000 1101 | 2.215000 0.885000 6.900000 1102 | 1.460000 0.885000 7.655000 1103 | 1.450000 0.885000 7.665000 1104 | 1.440000 0.885000 7.675000 1105 | 1.440000 1.440000 8.230000 1106 | 1.450000 1.440000 8.240000 1107 | 1.450000 4.215000 11.015000 1108 | 2.560000 4.560000 12.470000 1109 | 2.560000 4.560000 12.480000 1110 | 1.785000 4.560000 13.255000 1111 | 1.785000 0.885000 16.930000 1112 | 2.560000 0.885000 17.705000 1113 | 2.560000 2.560000 19.380000 1114 | 2.570000 2.560000 19.390000 1115 | 4.215000 2.560000 21.035000 1116 | 5.785000 5.115000 25.160000 1117 | 6.215000 5.115000 25.590000 1118 | 6.560000 1.440000 29.610000 1119 | 7.115000 1.440000 30.165000 1120 | 7.115000 6.215000 34.940000 1121 | 1.390000 6.610000 41.060000 1122 | 1.390000 6.620000 41.070000 1123 | 1.400000 6.620000 41.080000 1124 | 3.000000 6.620000 42.680000 1125 | 3.000000 7.000000 43.060000 1126 | 0.000000 1127 | 0.000000 1128 | 0.000000 1129 | 0.000000 1130 | 0.000000 1131 | 0.000000 1132 | 4.500000 2.000000 0.000000 1133 | 2.510000 0.590000 1.133333 1134 | 1.470000 0.590000 1.480000 1135 | 1.440000 0.590000 1.490000 1136 | 1.440000 1.440000 1.773333 1137 | 1.440000 4.380000 2.753333 1138 | 1.440000 4.410000 2.763333 1139 | 1.440000 4.440000 2.773333 1140 | 1.440000 4.510000 2.796667 1141 | 2.560000 4.560000 3.186667 1142 | 2.560000 4.560000 3.196667 1143 | 1.490000 4.510000 3.570000 1144 | 1.490000 0.590000 4.876667 1145 | 1.520000 0.590000 4.886667 1146 | 2.510000 0.590000 5.216667 1147 | 2.560000 2.560000 5.890000 1148 | 2.590000 2.560000 5.900000 1149 | 4.510000 3.490000 6.850000 1150 | 5.490000 5.410000 7.816667 1151 | 6.510000 5.410000 8.156667 1152 | 6.560000 1.440000 9.496667 1153 | 6.560000 1.440000 9.506667 1154 | 6.510000 5.410000 10.846667 1155 | 5.490000 5.410000 11.186667 1156 | 5.440000 1.440000 12.526667 1157 | 5.410000 1.440000 12.536667 1158 | 5.410000 1.440000 12.546667 1159 | 4.500000 2.000000 0.000000 1160 | 3.440000 2.560000 0.540000 1161 | 3.440000 2.590000 0.550000 1162 | 4.510000 2.590000 0.906667 1163 | 4.510000 5.410000 1.846667 1164 | 6.510000 5.410000 2.513333 1165 | 6.560000 1.440000 3.853333 1166 | 6.560000 1.440000 3.863333 1167 | 6.560000 5.410000 5.186667 1168 | 5.490000 5.410000 5.543333 1169 | 5.490000 0.590000 7.150000 1170 | 1.490000 0.590000 8.483333 1171 | 1.490000 4.510000 9.790000 1172 | 2.510000 4.510000 10.130000 1173 | 2.540000 4.510000 10.140000 1174 | 2.560000 4.560000 10.163333 1175 | 2.560000 4.560000 10.173333 1176 | 1.490000 4.560000 10.530000 1177 | 1.440000 1.440000 11.586667 1178 | 1.440000 0.590000 11.870000 1179 | 4.560000 0.590000 12.910000 1180 | 4.560000 0.620000 12.920000 1181 | 4.560000 5.410000 14.516667 1182 | 7.410000 5.410000 15.466667 1183 | 7.410000 6.510000 15.833333 1184 | 1.390000 6.610000 17.873333 1185 | 1.360000 6.610000 17.883333 1186 | 4.500000 2.000000 0.000000 1187 | 4.510000 2.020000 0.010000 1188 | 4.510000 5.410000 1.140000 1189 | 7.410000 5.410000 2.106667 1190 | 7.410000 6.510000 2.473333 1191 | 2.570000 6.510000 4.086667 1192 | 2.540000 6.510000 4.096667 1193 | 2.510000 6.510000 4.106667 1194 | 1.390000 6.610000 4.513333 1195 | 1.390000 6.610000 4.523333 1196 | 7.410000 6.510000 6.563333 1197 | 7.410000 1.440000 8.253333 1198 | 6.560000 1.440000 8.536667 1199 | 6.560000 5.410000 9.860000 1200 | 4.560000 5.410000 10.526667 1201 | 4.560000 1.440000 11.850000 1202 | 4.560000 0.590000 12.133333 1203 | 1.490000 0.590000 13.156667 1204 | 1.490000 4.510000 14.463333 1205 | 2.560000 4.560000 14.836667 1206 | 2.560000 4.560000 14.846667 1207 | 1.490000 4.560000 15.203333 1208 | 1.440000 1.440000 16.260000 1209 | 1.440000 0.590000 16.543333 1210 | 2.510000 0.590000 16.900000 1211 | 2.560000 2.560000 17.573333 1212 | 2.560000 2.590000 17.583333 1213 | 4.500000 2.000000 0.000000 1214 | 3.440000 2.560000 0.540000 1215 | 3.440000 2.590000 0.550000 1216 | 4.510000 2.590000 0.906667 1217 | 4.510000 5.410000 1.846667 1218 | 6.510000 5.410000 2.513333 1219 | 6.560000 1.440000 3.853333 1220 | 6.560000 1.440000 3.863333 1221 | 6.560000 5.410000 5.186667 1222 | 5.490000 5.410000 5.543333 1223 | 5.490000 0.590000 7.150000 1224 | 1.490000 0.590000 8.483333 1225 | 1.490000 4.510000 9.790000 1226 | 2.510000 4.510000 10.130000 1227 | 2.540000 4.510000 10.140000 1228 | 2.560000 4.560000 10.163333 1229 | 2.560000 4.560000 10.173333 1230 | 1.490000 4.560000 10.530000 1231 | 1.440000 1.440000 11.586667 1232 | 1.440000 0.590000 11.870000 1233 | 4.560000 0.590000 12.910000 1234 | 4.560000 0.620000 12.920000 1235 | 4.560000 5.410000 14.516667 1236 | 7.410000 5.410000 15.466667 1237 | 7.410000 6.510000 15.833333 1238 | 1.390000 6.610000 17.873333 1239 | 1.360000 6.610000 17.883333 1240 | 0.000000 1241 | 0.000000 1242 | 0.000000 1243 | 4.500000 2.000000 0.000000 1244 | 3.440000 2.560000 0.540000 1245 | 3.440000 2.560000 0.550000 1246 | 4.560000 1.410000 1.306667 1247 | 4.560000 0.590000 1.580000 1248 | 1.440000 0.590000 2.620000 1249 | 1.440000 0.590000 2.630000 1250 | 4.510000 0.590000 3.653333 1251 | 5.490000 5.410000 5.586667 1252 | 6.510000 5.410000 5.926667 1253 | 6.560000 1.440000 7.266667 1254 | 6.560000 1.440000 7.276667 1255 | 6.510000 5.410000 8.616667 1256 | 5.490000 5.410000 8.956667 1257 | 4.510000 0.590000 10.890000 1258 | 1.490000 0.590000 11.896667 1259 | 1.490000 4.510000 13.203333 1260 | 2.560000 4.560000 13.576667 1261 | 2.560000 4.560000 13.586667 1262 | 1.490000 4.510000 13.960000 1263 | 1.490000 0.590000 15.266667 1264 | 4.510000 0.590000 16.273333 1265 | 4.510000 5.410000 17.880000 1266 | 7.410000 5.410000 18.846667 1267 | 7.410000 6.510000 19.213333 1268 | 1.390000 6.610000 21.253333 1269 | 1.390000 6.610000 21.263333 1270 | 4.500000 2.000000 0.000000 1271 | 3.440000 2.560000 0.540000 1272 | 3.440000 2.560000 0.550000 1273 | 4.560000 1.410000 1.306667 1274 | 4.560000 0.590000 1.580000 1275 | 1.440000 0.590000 2.620000 1276 | 1.440000 0.590000 2.630000 1277 | 4.510000 0.590000 3.653333 1278 | 5.490000 5.410000 5.586667 1279 | 6.510000 5.410000 5.926667 1280 | 6.560000 1.440000 7.266667 1281 | 6.560000 1.440000 7.276667 1282 | 6.510000 5.410000 8.616667 1283 | 5.490000 5.410000 8.956667 1284 | 4.510000 0.590000 10.890000 1285 | 1.490000 0.590000 11.896667 1286 | 1.490000 4.510000 13.203333 1287 | 2.560000 4.560000 13.576667 1288 | 2.560000 4.560000 13.586667 1289 | 1.490000 4.510000 13.960000 1290 | 1.490000 0.590000 15.266667 1291 | 4.510000 0.590000 16.273333 1292 | 4.510000 5.410000 17.880000 1293 | 7.410000 5.410000 18.846667 1294 | 7.410000 6.510000 19.213333 1295 | 1.390000 6.610000 21.253333 1296 | 1.390000 6.610000 21.263333 1297 | 0.000000 1298 | 0.000000 1299 | 0.000000 1300 | 4.500000 2.000000 0.000000 1301 | 3.440000 2.560000 0.540000 1302 | 3.440000 2.560000 0.550000 1303 | 4.560000 1.410000 1.306667 1304 | 4.560000 0.590000 1.580000 1305 | 1.440000 0.590000 2.620000 1306 | 1.440000 0.590000 2.630000 1307 | 4.510000 0.590000 3.653333 1308 | 5.490000 5.410000 5.586667 1309 | 6.510000 5.410000 5.926667 1310 | 6.560000 1.440000 7.266667 1311 | 6.560000 1.440000 7.276667 1312 | 6.510000 5.410000 8.616667 1313 | 5.490000 5.410000 8.956667 1314 | 4.510000 0.590000 10.890000 1315 | 1.490000 0.590000 11.896667 1316 | 1.490000 4.510000 13.203333 1317 | 2.560000 4.560000 13.576667 1318 | 2.560000 4.560000 13.586667 1319 | 1.490000 4.510000 13.960000 1320 | 1.490000 0.590000 15.266667 1321 | 4.510000 0.590000 16.273333 1322 | 4.510000 5.410000 17.880000 1323 | 7.410000 5.410000 18.846667 1324 | 7.410000 6.510000 19.213333 1325 | 1.390000 6.610000 21.253333 1326 | 1.390000 6.610000 21.263333 1327 | 4.500000 2.000000 0.000000 1328 | 3.440000 2.560000 0.540000 1329 | 3.440000 2.560000 0.550000 1330 | 4.560000 1.410000 1.306667 1331 | 4.560000 0.590000 1.580000 1332 | 1.440000 0.590000 2.620000 1333 | 1.440000 0.590000 2.630000 1334 | 4.510000 0.590000 3.653333 1335 | 4.510000 5.410000 5.260000 1336 | 6.560000 5.410000 5.943333 1337 | 6.560000 1.440000 7.266667 1338 | 6.560000 1.440000 7.276667 1339 | 6.560000 5.410000 8.600000 1340 | 5.490000 5.410000 8.956667 1341 | 5.490000 0.590000 10.563333 1342 | 1.490000 0.590000 11.896667 1343 | 1.490000 4.510000 13.203333 1344 | 2.560000 4.560000 13.576667 1345 | 2.560000 4.560000 13.586667 1346 | 1.490000 4.510000 13.960000 1347 | 1.490000 0.590000 15.266667 1348 | 5.490000 0.590000 16.600000 1349 | 5.490000 5.410000 18.206667 1350 | 7.410000 5.410000 18.846667 1351 | 7.410000 6.510000 19.213333 1352 | 1.390000 6.610000 21.253333 1353 | 1.390000 6.640000 21.263333 1354 | 0.000000 1355 | 0.000000 1356 | 0.000000 1357 | 0.000000 1358 | 0.000000 1359 | 0.000000 1360 | 4.500000 2.000000 0.000000 1361 | 4.560000 1.440000 0.206667 1362 | 4.560000 1.440000 0.216667 1363 | 1.440000 1.440000 1.256667 1364 | 1.440000 1.440000 1.266667 1365 | 2.410000 1.440000 1.590000 1366 | 2.560000 4.560000 2.680000 1367 | 2.560000 4.560000 2.690000 1368 | 2.530000 4.560000 2.700000 1369 | 2.530000 4.510000 2.716667 1370 | -0.410000 4.510000 3.696667 1371 | -0.410000 3.440000 4.053333 1372 | 2.560000 3.440000 5.043333 1373 | 2.560000 3.440000 5.053333 1374 | 2.560000 3.440000 5.063333 1375 | 2.560000 3.470000 5.073333 1376 | 2.560000 4.510000 5.420000 1377 | 1.390000 6.610000 6.510000 1378 | 1.390000 6.610000 6.520000 1379 | 6.470000 6.610000 8.213333 1380 | 6.500000 6.610000 8.223333 1381 | 6.500000 1.470000 9.936667 1382 | 6.500000 1.440000 9.946667 1383 | 6.530000 1.440000 9.956667 1384 | 6.560000 1.440000 9.966667 1385 | 6.590000 1.440000 9.976667 1386 | 6.560000 1.440000 9.986667 1387 | 4.500000 2.000000 0.000000 1388 | 3.440000 2.560000 0.540000 1389 | 3.440000 2.560000 0.550000 1390 | 4.560000 1.410000 1.306667 1391 | 4.560000 0.590000 1.580000 1392 | 1.440000 0.590000 2.620000 1393 | 1.440000 0.590000 2.630000 1394 | 4.510000 0.590000 3.653333 1395 | 4.510000 5.410000 5.260000 1396 | 6.560000 5.410000 5.943333 1397 | 6.560000 1.440000 7.266667 1398 | 6.560000 1.440000 7.276667 1399 | 6.560000 5.410000 8.600000 1400 | 5.490000 5.410000 8.956667 1401 | 5.490000 0.590000 10.563333 1402 | 1.490000 0.590000 11.896667 1403 | 1.490000 4.510000 13.203333 1404 | 2.560000 4.560000 13.576667 1405 | 2.560000 4.560000 13.586667 1406 | 1.490000 4.510000 13.960000 1407 | 1.490000 0.590000 15.266667 1408 | 5.490000 0.590000 16.600000 1409 | 5.490000 5.410000 18.206667 1410 | 7.410000 5.410000 18.846667 1411 | 7.410000 6.510000 19.213333 1412 | 1.390000 6.610000 21.253333 1413 | 1.390000 6.640000 21.263333 1414 | 0.000000 1415 | 0.000000 1416 | 0.000000 1417 | 0.000000 1418 | 0.000000 1419 | 0.000000 1420 | 0.000000 1421 | 0.000000 1422 | 0.000000 1423 | 0.000000 1424 | 0.000000 1425 | 0.000000 1426 | 4.500000 2.000000 0.000000 1427 | 3.440000 2.560000 0.540000 1428 | 3.440000 2.560000 0.550000 1429 | 4.560000 1.410000 1.306667 1430 | 4.560000 0.590000 1.580000 1431 | 1.440000 0.590000 2.620000 1432 | 1.440000 0.590000 2.630000 1433 | 4.510000 0.590000 3.653333 1434 | 4.510000 5.410000 5.260000 1435 | 6.560000 5.410000 5.943333 1436 | 6.560000 1.440000 7.266667 1437 | 6.560000 1.440000 7.276667 1438 | 6.560000 5.410000 8.600000 1439 | 5.490000 5.410000 8.956667 1440 | 5.490000 0.590000 10.563333 1441 | 1.490000 0.590000 11.896667 1442 | 1.490000 4.510000 13.203333 1443 | 2.560000 4.560000 13.576667 1444 | 2.560000 4.560000 13.586667 1445 | 1.490000 4.510000 13.960000 1446 | 1.490000 0.590000 15.266667 1447 | 5.490000 0.590000 16.600000 1448 | 5.490000 5.410000 18.206667 1449 | 7.410000 5.410000 18.846667 1450 | 7.410000 6.510000 19.213333 1451 | 1.390000 6.610000 21.253333 1452 | 1.390000 6.640000 21.263333 1453 | 0.000000 1454 | 0.000000 1455 | 0.000000 1456 | 0.000000 1457 | 0.000000 1458 | 0.000000 1459 | 0.000000 1460 | 0.000000 1461 | 0.000000 1462 | 0.000000 1463 | 0.000000 1464 | 0.000000 1465 | 4.500000 2.000000 0.000000 1466 | 3.440000 2.560000 0.540000 1467 | 3.440000 2.560000 0.550000 1468 | 4.560000 1.440000 1.296667 1469 | 4.560000 0.590000 1.580000 1470 | 1.440000 0.590000 2.620000 1471 | 1.440000 0.590000 2.630000 1472 | 4.510000 0.590000 3.653333 1473 | 4.510000 5.410000 5.260000 1474 | 6.510000 5.410000 5.926667 1475 | 6.560000 1.440000 7.266667 1476 | 6.560000 1.440000 7.276667 1477 | 6.510000 5.410000 8.616667 1478 | 4.510000 5.410000 9.283333 1479 | 4.510000 0.590000 10.890000 1480 | 1.490000 0.590000 11.896667 1481 | 1.490000 4.510000 13.203333 1482 | 2.560000 4.560000 13.576667 1483 | 2.560000 4.560000 13.586667 1484 | 1.490000 4.510000 13.960000 1485 | 1.490000 4.480000 13.970000 1486 | 1.490000 0.590000 15.266667 1487 | 4.510000 0.590000 16.273333 1488 | 4.510000 5.490000 17.906667 1489 | 7.410000 5.490000 18.873333 1490 | 7.410000 6.510000 19.213333 1491 | 7.380000 6.510000 19.223333 1492 | 4.510000 6.510000 20.180000 1493 | 1.390000 6.610000 21.253333 1494 | 1.390000 6.640000 21.263333 1495 | 1.390000 6.670000 21.273333 1496 | 4.500000 2.000000 0.000000 1497 | 3.440000 2.560000 0.540000 1498 | 3.440000 2.560000 0.550000 1499 | 4.560000 1.440000 1.296667 1500 | 4.560000 0.590000 1.580000 1501 | 1.440000 0.590000 2.620000 1502 | 1.440000 0.590000 2.630000 1503 | 4.510000 0.590000 3.653333 1504 | 4.510000 5.410000 5.260000 1505 | 6.510000 5.410000 5.926667 1506 | 6.560000 1.440000 7.266667 1507 | 6.560000 1.440000 7.276667 1508 | 6.510000 5.410000 8.616667 1509 | 4.510000 5.410000 9.283333 1510 | 4.510000 0.590000 10.890000 1511 | 1.490000 0.590000 11.896667 1512 | 1.490000 4.510000 13.203333 1513 | 2.560000 4.560000 13.576667 1514 | 2.560000 4.560000 13.586667 1515 | 1.490000 4.510000 13.960000 1516 | 1.490000 4.480000 13.970000 1517 | 1.490000 0.590000 15.266667 1518 | 4.510000 0.590000 16.273333 1519 | 4.510000 5.490000 17.906667 1520 | 7.410000 5.490000 18.873333 1521 | 7.410000 6.510000 19.213333 1522 | 7.380000 6.510000 19.223333 1523 | 4.510000 6.510000 20.180000 1524 | 1.390000 6.610000 21.253333 1525 | 1.390000 6.640000 21.263333 1526 | 1.390000 6.670000 21.273333 1527 | 4.500000 2.000000 0.000000 1528 | 3.440000 2.560000 0.540000 1529 | 3.440000 2.560000 0.550000 1530 | 4.560000 0.620000 1.570000 1531 | 4.560000 0.590000 1.580000 1532 | 1.440000 0.590000 2.620000 1533 | 1.440000 0.590000 2.630000 1534 | 5.490000 0.590000 3.980000 1535 | 5.490000 5.410000 5.586667 1536 | 6.510000 5.410000 5.926667 1537 | 6.560000 1.440000 7.266667 1538 | 6.560000 1.440000 7.276667 1539 | 6.510000 5.410000 8.616667 1540 | 5.490000 5.410000 8.956667 1541 | 4.510000 0.590000 10.890000 1542 | 1.490000 0.590000 11.896667 1543 | 1.490000 4.510000 13.203333 1544 | 2.560000 4.560000 13.576667 1545 | 2.560000 4.560000 13.586667 1546 | 1.490000 4.510000 13.960000 1547 | 1.490000 0.590000 15.266667 1548 | 4.510000 0.590000 16.273333 1549 | 5.490000 5.410000 18.206667 1550 | 7.410000 5.410000 18.846667 1551 | 7.410000 5.380000 18.856667 1552 | 7.390000 4.390000 19.193333 1553 | 7.390000 4.390000 19.203333 1554 | 7.410000 5.490000 19.576667 1555 | 7.410000 6.510000 19.916667 1556 | 1.390000 6.610000 21.956667 1557 | 1.390000 6.640000 21.966667 1558 | 0.000000 1559 | 0.000000 1560 | 0.000000 1561 | 0.000000 1562 | 0.000000 1563 | 0.000000 1564 | 0.000000 1565 | 0.000000 1566 | 0.000000 1567 | 0.000000 1568 | 0.000000 1569 | 0.000000 1570 | 4.500000 2.000000 0.000000 1571 | 3.440000 2.560000 0.540000 1572 | 3.440000 2.560000 0.550000 1573 | 4.560000 0.620000 1.570000 1574 | 4.560000 0.590000 1.580000 1575 | 1.440000 0.590000 2.620000 1576 | 1.440000 0.590000 2.630000 1577 | 5.490000 0.590000 3.980000 1578 | 5.490000 5.410000 5.586667 1579 | 6.510000 5.410000 5.926667 1580 | 6.560000 1.440000 7.266667 1581 | 6.560000 1.440000 7.276667 1582 | 6.510000 5.410000 8.616667 1583 | 5.490000 5.410000 8.956667 1584 | 4.510000 0.590000 10.890000 1585 | 1.490000 0.590000 11.896667 1586 | 1.490000 4.510000 13.203333 1587 | 2.560000 4.560000 13.576667 1588 | 2.560000 4.560000 13.586667 1589 | 1.490000 4.510000 13.960000 1590 | 1.490000 0.590000 15.266667 1591 | 4.510000 0.590000 16.273333 1592 | 5.490000 5.410000 18.206667 1593 | 7.410000 5.410000 18.846667 1594 | 7.410000 5.380000 18.856667 1595 | 7.390000 4.390000 19.193333 1596 | 7.390000 4.390000 19.203333 1597 | 7.410000 5.490000 19.576667 1598 | 7.410000 6.510000 19.916667 1599 | 1.390000 6.610000 21.956667 1600 | 1.390000 6.640000 21.966667 1601 | 4.500000 2.000000 0.000000 1602 | 3.440000 2.560000 0.540000 1603 | 3.440000 2.560000 0.550000 1604 | 4.560000 0.620000 1.570000 1605 | 4.560000 0.590000 1.580000 1606 | 1.440000 0.590000 2.620000 1607 | 1.440000 0.590000 2.630000 1608 | 5.490000 0.590000 3.980000 1609 | 5.490000 5.410000 5.586667 1610 | 6.510000 5.410000 5.926667 1611 | 6.560000 1.440000 7.266667 1612 | 6.560000 1.440000 7.276667 1613 | 6.510000 5.410000 8.616667 1614 | 5.490000 5.410000 8.956667 1615 | 4.510000 0.590000 10.890000 1616 | 1.490000 0.590000 11.896667 1617 | 1.490000 4.510000 13.203333 1618 | 2.560000 4.560000 13.576667 1619 | 2.560000 4.560000 13.586667 1620 | 1.490000 4.510000 13.960000 1621 | 1.490000 0.590000 15.266667 1622 | 4.510000 0.590000 16.273333 1623 | 5.490000 5.410000 18.206667 1624 | 7.410000 5.410000 18.846667 1625 | 7.410000 5.380000 18.856667 1626 | 7.390000 4.390000 19.193333 1627 | 7.390000 4.390000 19.203333 1628 | 7.410000 5.490000 19.576667 1629 | 7.410000 6.510000 19.916667 1630 | 1.390000 6.610000 21.956667 1631 | 1.390000 6.640000 21.966667 1632 | 4.500000 2.000000 0.000000 1633 | 3.440000 2.560000 0.540000 1634 | 3.440000 2.560000 0.550000 1635 | 4.560000 0.620000 1.570000 1636 | 4.560000 0.590000 1.580000 1637 | 1.440000 0.590000 2.620000 1638 | 1.440000 0.590000 2.630000 1639 | 5.490000 0.590000 3.980000 1640 | 5.490000 5.410000 5.586667 1641 | 6.510000 5.410000 5.926667 1642 | 6.560000 1.440000 7.266667 1643 | 6.560000 1.440000 7.276667 1644 | 6.510000 5.410000 8.616667 1645 | 5.490000 5.410000 8.956667 1646 | 4.510000 0.590000 10.890000 1647 | 1.490000 0.590000 11.896667 1648 | 1.490000 4.510000 13.203333 1649 | 2.560000 4.560000 13.576667 1650 | 2.560000 4.560000 13.586667 1651 | 1.490000 4.510000 13.960000 1652 | 1.490000 0.590000 15.266667 1653 | 4.510000 0.590000 16.273333 1654 | 5.490000 5.410000 18.206667 1655 | 7.410000 5.410000 18.846667 1656 | 7.410000 5.380000 18.856667 1657 | 7.390000 4.390000 19.193333 1658 | 7.390000 4.390000 19.203333 1659 | 7.410000 5.490000 19.576667 1660 | 7.410000 6.510000 19.916667 1661 | 1.390000 6.610000 21.956667 1662 | 1.390000 6.640000 21.966667 1663 | 0.000000 1664 | 0.000000 1665 | 0.000000 1666 | 4.500000 2.000000 0.000000 1667 | 3.440000 2.560000 0.540000 1668 | 3.440000 2.560000 0.550000 1669 | 4.560000 0.620000 1.570000 1670 | 4.560000 0.590000 1.580000 1671 | 1.440000 0.590000 2.620000 1672 | 1.440000 0.590000 2.630000 1673 | 5.490000 0.590000 3.980000 1674 | 5.490000 5.410000 5.586667 1675 | 6.510000 5.410000 5.926667 1676 | 6.560000 1.440000 7.266667 1677 | 6.560000 1.440000 7.276667 1678 | 6.510000 5.410000 8.616667 1679 | 5.490000 5.410000 8.956667 1680 | 4.510000 0.590000 10.890000 1681 | 1.490000 0.590000 11.896667 1682 | 1.490000 4.510000 13.203333 1683 | 2.560000 4.560000 13.576667 1684 | 2.560000 4.560000 13.586667 1685 | 1.490000 4.510000 13.960000 1686 | 1.490000 0.590000 15.266667 1687 | 4.510000 0.590000 16.273333 1688 | 5.490000 5.410000 18.206667 1689 | 7.410000 5.410000 18.846667 1690 | 7.410000 5.380000 18.856667 1691 | 7.390000 4.390000 19.193333 1692 | 7.390000 4.390000 19.203333 1693 | 7.410000 5.490000 19.576667 1694 | 7.410000 6.510000 19.916667 1695 | 1.390000 6.610000 21.956667 1696 | 1.390000 6.640000 21.966667 1697 | 4.500000 2.000000 0.000000 1698 | 3.440000 2.560000 0.540000 1699 | 3.440000 2.560000 0.550000 1700 | 4.560000 0.620000 1.570000 1701 | 4.560000 0.590000 1.580000 1702 | 1.440000 0.590000 2.620000 1703 | 1.440000 0.590000 2.630000 1704 | 5.490000 0.590000 3.980000 1705 | 5.490000 5.410000 5.586667 1706 | 6.510000 5.410000 5.926667 1707 | 6.560000 1.440000 7.266667 1708 | 6.560000 1.440000 7.276667 1709 | 6.510000 5.410000 8.616667 1710 | 5.490000 5.410000 8.956667 1711 | 4.510000 0.590000 10.890000 1712 | 1.490000 0.590000 11.896667 1713 | 1.490000 4.510000 13.203333 1714 | 2.560000 4.560000 13.576667 1715 | 2.560000 4.560000 13.586667 1716 | 1.490000 4.510000 13.960000 1717 | 1.490000 0.590000 15.266667 1718 | 4.510000 0.590000 16.273333 1719 | 5.490000 5.410000 18.206667 1720 | 7.410000 5.410000 18.846667 1721 | 7.410000 5.380000 18.856667 1722 | 7.390000 4.390000 19.193333 1723 | 7.390000 4.390000 19.203333 1724 | 7.410000 5.490000 19.576667 1725 | 7.410000 6.510000 19.916667 1726 | 1.390000 6.610000 21.956667 1727 | 1.390000 6.640000 21.966667 1728 | 4.500000 2.000000 0.000000 1729 | 3.440000 2.560000 0.540000 1730 | 3.440000 2.560000 0.550000 1731 | 4.560000 0.620000 1.570000 1732 | 4.560000 0.590000 1.580000 1733 | 1.440000 0.590000 2.620000 1734 | 1.440000 0.590000 2.630000 1735 | 5.490000 0.590000 3.980000 1736 | 5.490000 5.410000 5.586667 1737 | 6.510000 5.410000 5.926667 1738 | 6.560000 1.440000 7.266667 1739 | 6.560000 1.440000 7.276667 1740 | 6.510000 5.410000 8.616667 1741 | 5.490000 5.410000 8.956667 1742 | 4.510000 0.590000 10.890000 1743 | 1.490000 0.590000 11.896667 1744 | 1.490000 4.510000 13.203333 1745 | 2.560000 4.560000 13.576667 1746 | 2.560000 4.560000 13.586667 1747 | 1.490000 4.510000 13.960000 1748 | 1.490000 0.590000 15.266667 1749 | 4.510000 0.590000 16.273333 1750 | 5.490000 5.410000 18.206667 1751 | 7.410000 5.410000 18.846667 1752 | 7.410000 5.380000 18.856667 1753 | 7.390000 4.390000 19.193333 1754 | 7.390000 4.390000 19.203333 1755 | 7.410000 5.490000 19.576667 1756 | 7.410000 6.510000 19.916667 1757 | 1.390000 6.610000 21.956667 1758 | 1.390000 6.640000 21.966667 1759 | 4.500000 2.000000 0.000000 1760 | 3.440000 2.560000 0.540000 1761 | 3.440000 2.560000 0.550000 1762 | 4.560000 0.620000 1.570000 1763 | 4.560000 0.590000 1.580000 1764 | 1.440000 0.590000 2.620000 1765 | 1.440000 0.590000 2.630000 1766 | 5.490000 0.590000 3.980000 1767 | 5.490000 5.410000 5.586667 1768 | 6.510000 5.410000 5.926667 1769 | 6.560000 1.440000 7.266667 1770 | 6.560000 1.440000 7.276667 1771 | 6.510000 5.410000 8.616667 1772 | 5.490000 5.410000 8.956667 1773 | 4.510000 0.590000 10.890000 1774 | 1.490000 0.590000 11.896667 1775 | 1.490000 4.510000 13.203333 1776 | 2.560000 4.560000 13.576667 1777 | 2.560000 4.560000 13.586667 1778 | 1.490000 4.510000 13.960000 1779 | 1.490000 0.590000 15.266667 1780 | 4.510000 0.590000 16.273333 1781 | 5.490000 5.410000 18.206667 1782 | 7.410000 5.410000 18.846667 1783 | 7.410000 5.380000 18.856667 1784 | 7.390000 4.390000 19.193333 1785 | 7.390000 4.390000 19.203333 1786 | 7.410000 5.490000 19.576667 1787 | 7.410000 6.510000 19.916667 1788 | 1.390000 6.610000 21.956667 1789 | 1.390000 6.640000 21.966667 1790 | 4.500000 2.000000 0.000000 1791 | 3.440000 2.560000 0.540000 1792 | 3.440000 2.560000 0.550000 1793 | 4.560000 0.620000 1.570000 1794 | 4.560000 0.590000 1.580000 1795 | 1.440000 0.590000 2.620000 1796 | 1.440000 0.590000 2.630000 1797 | 5.490000 0.590000 3.980000 1798 | 5.490000 5.410000 5.586667 1799 | 6.510000 5.410000 5.926667 1800 | 6.560000 1.440000 7.266667 1801 | 6.560000 1.440000 7.276667 1802 | 6.510000 5.410000 8.616667 1803 | 5.490000 5.410000 8.956667 1804 | 4.510000 0.590000 10.890000 1805 | 1.490000 0.590000 11.896667 1806 | 1.490000 4.510000 13.203333 1807 | 2.560000 4.560000 13.576667 1808 | 2.560000 4.560000 13.586667 1809 | 1.490000 4.510000 13.960000 1810 | 1.490000 0.590000 15.266667 1811 | 4.510000 0.590000 16.273333 1812 | 5.490000 5.410000 18.206667 1813 | 7.410000 5.410000 18.846667 1814 | 7.410000 5.380000 18.856667 1815 | 7.390000 4.390000 19.193333 1816 | 7.390000 4.390000 19.203333 1817 | 7.410000 5.490000 19.576667 1818 | 7.410000 6.510000 19.916667 1819 | 1.390000 6.610000 21.956667 1820 | 1.390000 6.640000 21.966667 1821 | -1.350000 -1.100000 0.000000 1822 | -1.340000 -1.100000 0.010000 1823 | -1.330000 -1.100000 0.020000 1824 | -1.320000 -1.100000 0.030000 1825 | -1.310000 -1.100000 0.040000 1826 | -1.300000 -1.100000 0.050000 1827 | -1.290000 -1.100000 0.060000 1828 | -1.090000 -1.100000 0.260000 1829 | -1.080000 -1.100000 0.270000 1830 | 0.110000 -1.100000 1.460000 1831 | 0.120000 -1.100000 1.470000 1832 | 0.130000 -1.100000 1.480000 1833 | 0.130000 -1.090000 1.490000 1834 | 1.090000 0.310000 3.850000 1835 | 1.100000 0.310000 3.860000 1836 | 1.110000 0.310000 3.870000 1837 | 1.120000 0.310000 3.880000 1838 | 1.130000 0.310000 3.890000 1839 | 1.140000 0.310000 3.900000 1840 | 1.150000 0.310000 3.910000 1841 | 1.150000 1.150000 4.750000 1842 | -1.350000 -1.100000 0.000000 1843 | -1.350000 -1.090000 0.010000 1844 | -1.090000 0.060000 1.420000 1845 | -1.080000 0.060000 1.430000 1846 | -1.080000 0.050000 1.440000 1847 | -1.080000 -0.740000 2.230000 1848 | -1.080000 -0.750000 2.240000 1849 | -1.080000 -0.760000 2.250000 1850 | -1.080000 -0.770000 2.260000 1851 | -1.080000 -0.780000 2.270000 1852 | -1.080000 -0.790000 2.280000 1853 | -1.080000 -0.800000 2.290000 1854 | -1.080000 -0.810000 2.300000 1855 | -1.070000 -0.810000 2.310000 1856 | -1.060000 -0.810000 2.320000 1857 | -1.050000 -0.810000 2.330000 1858 | -1.040000 -0.810000 2.340000 1859 | 0.110000 -0.810000 3.490000 1860 | 0.120000 -0.810000 3.500000 1861 | 0.485000 0.915000 5.590000 1862 | 1.150000 1.150000 6.490000 1863 | -1.350000 -1.100000 0.000000 1864 | -1.290000 0.910000 2.070000 1865 | -1.280000 0.910000 2.080000 1866 | -1.270000 0.910000 2.090000 1867 | -1.260000 0.910000 2.100000 1868 | -1.250000 0.910000 2.110000 1869 | -1.240000 0.910000 2.120000 1870 | -1.230000 0.910000 2.130000 1871 | -1.220000 0.910000 2.140000 1872 | -1.210000 0.910000 2.150000 1873 | -1.200000 0.910000 2.160000 1874 | -1.190000 0.910000 2.170000 1875 | -1.180000 0.910000 2.180000 1876 | -1.170000 0.910000 2.190000 1877 | -1.160000 0.910000 2.200000 1878 | -1.150000 0.910000 2.210000 1879 | -1.140000 0.910000 2.220000 1880 | -1.130000 0.910000 2.230000 1881 | 0.615000 0.910000 3.975000 1882 | 0.625000 0.910000 3.985000 1883 | 1.150000 1.150000 4.750000 1884 | 0.000000 1885 | 0.000000 1886 | 0.000000 1887 | -1.350000 -1.100000 0.000000 1888 | -1.350000 -1.090000 0.010000 1889 | -1.350000 -1.080000 0.020000 1890 | -1.350000 -1.070000 0.030000 1891 | -1.350000 -1.060000 0.040000 1892 | -1.350000 -1.050000 0.050000 1893 | -1.350000 -1.040000 0.060000 1894 | -1.350000 -1.030000 0.070000 1895 | -1.350000 -1.020000 0.080000 1896 | -1.350000 -1.010000 0.090000 1897 | -1.350000 -1.000000 0.100000 1898 | -1.350000 -0.990000 0.110000 1899 | -1.350000 -0.980000 0.120000 1900 | -1.350000 -0.970000 0.130000 1901 | -1.350000 0.615000 1.715000 1902 | 0.310000 0.910000 3.670000 1903 | 0.310000 0.920000 3.680000 1904 | 0.300000 0.920000 3.690000 1905 | -0.310000 0.920000 4.300000 1906 | -0.310000 0.930000 4.310000 1907 | 1.150000 1.150000 5.990000 1908 | -1.350000 -1.100000 0.000000 1909 | -1.350000 -0.615000 0.485000 1910 | -1.340000 -0.615000 0.495000 1911 | -0.625000 -0.615000 1.210000 1912 | -0.615000 -0.615000 1.220000 1913 | -0.615000 -0.605000 1.230000 1914 | -0.615000 0.910000 2.745000 1915 | 0.310000 0.910000 3.670000 1916 | 0.310000 0.920000 3.680000 1917 | -0.300000 0.920000 4.290000 1918 | -0.310000 0.920000 4.300000 1919 | -0.310000 0.930000 4.310000 1920 | -0.310000 0.940000 4.320000 1921 | -0.310000 0.950000 4.330000 1922 | -0.310000 0.960000 4.340000 1923 | -0.310000 0.970000 4.350000 1924 | -0.310000 0.980000 4.360000 1925 | -0.310000 0.990000 4.370000 1926 | -0.310000 1.140000 4.520000 1927 | -0.310000 1.150000 4.530000 1928 | 1.150000 1.150000 5.990000 1929 | -1.350000 -1.100000 0.000000 1930 | -1.350000 0.910000 2.010000 1931 | 0.310000 0.910000 3.670000 1932 | 0.310000 0.920000 3.680000 1933 | -1.060000 0.920000 5.050000 1934 | -1.070000 0.920000 5.060000 1935 | -1.080000 0.920000 5.070000 1936 | -1.090000 0.920000 5.080000 1937 | -1.100000 0.920000 5.090000 1938 | -1.110000 0.920000 5.100000 1939 | -1.120000 0.920000 5.110000 1940 | -1.130000 0.920000 5.120000 1941 | -1.140000 0.920000 5.130000 1942 | -1.150000 0.920000 5.140000 1943 | -1.150000 0.930000 5.150000 1944 | -1.150000 0.940000 5.160000 1945 | -1.150000 0.950000 5.170000 1946 | -1.150000 0.960000 5.180000 1947 | -1.150000 0.970000 5.190000 1948 | -1.150000 0.980000 5.200000 1949 | -1.150000 1.150000 5.370000 1950 | 1.350000 -1.100000 0.000000 1951 | 1.350000 0.615000 1.715000 1952 | 1.340000 0.615000 1.725000 1953 | 0.330000 0.615000 2.735000 1954 | 0.320000 0.615000 2.745000 1955 | 0.320000 0.910000 3.040000 1956 | 0.310000 0.910000 3.050000 1957 | -1.070000 0.910000 4.430000 1958 | -1.080000 0.910000 4.440000 1959 | -1.090000 0.910000 4.450000 1960 | -1.100000 0.910000 4.460000 1961 | -1.110000 0.910000 4.470000 1962 | -1.120000 0.910000 4.480000 1963 | -1.130000 0.910000 4.490000 1964 | -1.140000 0.910000 4.500000 1965 | -1.150000 0.910000 4.510000 1966 | -1.150000 0.920000 4.520000 1967 | -1.150000 0.930000 4.530000 1968 | -1.150000 0.940000 4.540000 1969 | -1.150000 0.950000 4.550000 1970 | -1.150000 1.150000 4.750000 1971 | 0.000000 1972 | 0.000000 1973 | 0.000000 1974 | 4.500000 2.000000 0.000000 1975 | 4.560000 1.440000 0.206667 1976 | 4.560000 1.440000 0.216667 1977 | 3.440000 2.560000 0.963333 1978 | 2.560000 2.560000 1.256667 1979 | 2.560000 0.590000 1.913333 1980 | 1.440000 0.590000 2.286667 1981 | 1.440000 0.590000 2.296667 1982 | 4.510000 0.590000 3.320000 1983 | 4.510000 5.410000 4.926667 1984 | 6.510000 5.410000 5.593333 1985 | 6.560000 1.440000 6.933333 1986 | 6.560000 1.440000 6.943333 1987 | 6.560000 5.410000 8.266667 1988 | 5.490000 5.410000 8.623333 1989 | 5.490000 0.590000 10.230000 1990 | 1.490000 0.590000 11.563333 1991 | 1.490000 4.560000 12.886667 1992 | 2.560000 4.560000 13.243333 1993 | 2.560000 4.560000 13.253333 1994 | 1.490000 4.510000 13.626667 1995 | 1.490000 0.590000 14.933333 1996 | 5.490000 0.590000 16.266667 1997 | 5.490000 5.410000 17.873333 1998 | 6.510000 5.410000 18.213333 1999 | 6.810000 4.390000 18.653333 2000 | 6.840000 4.390000 18.663333 2001 | 7.410000 5.490000 19.220000 2002 | 7.410000 6.510000 19.560000 2003 | 1.390000 6.610000 21.600000 2004 | 1.360000 6.610000 21.610000 2005 | 0.000000 2006 | 0.000000 2007 | 0.000000 2008 | -------------------------------------------------------------------------------- /llm_task_plan.py: -------------------------------------------------------------------------------- 1 | from openai_func import * 2 | import random 3 | import os 4 | 5 | domain = 'chip' # 'HouseWorld' or 'chip' 6 | experiment_result_dir = 'path-to-submission_code/experiment_result' # the directory of experiment_result 7 | model_name = 'gpt-4' # 'gpt-3' or 'gpt-4' 8 | 9 | def end2end_prompt(sentence, start_location_list, end_location_list): 10 | part1="I am a mobile robot and I hope you can help me plan the trajectory to fulfill the navigation instruction. I will give you the position and size of each box in the whole environment and the instruction is to enter or avoid the box. Each box is of square shape, I will give you (x_start, x_end, y_start, y_end) to describe the shape of square. x_start, x_end denote the boundary of squares in x coordinates. y_start, y_end denote the boundary of squares in y coordinates.\n\nDuring navigation, the trajectory should always not touch the black wall. The entrance of the car in each box is denoted by the whole area of the car is within the box area. The avoidance of the car in each box is denoted by the complete division of the car and the box area. I will give you the starting and ending locations of the robot. The car should fulfill the instruction, start from the starting location and in the end stop at the ending location.\n\nCould you give me the trajectory to realize the above instruction. Please report a list of the specific locations of transition points and the time point at each specific location, and the final trajectory is by connecting the linear line between these transition points. The velocity of the robot should not exceed 50.\n\nHere are examples:\nInput:\navailable scene objects: [name : room1, color: cyan, function: Kitchen, position and size: (1.2, -0.8, 1.4, -0.7)], [name : room2, color: red, function: RestRoom2, position and size: (0, 0.9, 1.4, -0.7)], [name : room3, color: green, function: MasterBedroom, position and size: (-0.2, 1.43, -0.8, 1.43)], [name : room4, color: pink, function: Bedroom, position and size: (-0.6, 1.43, -0.2, 0.8)], [name : room5, color: blue, function: LivingRoom, position and size: (0.5, 0.5, 0.5, 0.5)], [name : room6, color: blue, function: ExerciseRoom, position and size: (1.2, -0.7, 0.05, 0.5)], [name : room7, color: yellow, function: RestRoom, position and size: (1.4, -0.2, -0.8, 1.43)], [name : room8, color: purple, function: DiningRoom, position and size: (0.7, -0.3, 1.4, -0.8)]\nStarting location: [-1.35, -1.1]\nEnding location: [1.15, 1.15]\nsentence: Go to one room with cyan color, then enter the bedroom and finally reach the restroom.\nOutput: \nx_location, y_location, time_point\n-1.35, -1.1, 0\n-1.0, -1.1, 0.05\n1.1, 0.3, 1\n0.12, -1.1, 2\n1.1, 1.2, 4\n\nInput:\navailable scene objects: [name : room1, color: cyan, function: Kitchen, position and size: (1.2, -0.8, 1.4, -0.7)], [name : room2, color: red, function: RestRoom2, position and size: (0, 0.9, 1.4, -0.7)], [name : room3, color: green, function: MasterBedroom, position and size: (-0.2, 1.43, -0.8, 1.43)], [name : room4, color: pink, function: Bedroom, position and size: (-0.6, 1.43, -0.2, 0.8)], [name : room5, color: blue, function: LivingRoom, position and size: (0.5, 0.5, 0.5, 0.5)], [name : room6, color: blue, function: ExerciseRoom, position and size: (1.2, -0.7, 0.05, 0.5)], [name : room7, color: yellow, function: RestRoom, position and size: (1.4, -0.2, -0.8, 1.43)], [name : room8, color: purple, function: DiningRoom, position and size: (0.7, -0.3, 1.4, -0.8)]\nStarting location: [-1.35, -1.1]\nEnding location: [1.15, 1.15]\nsentence: Go to one room with yellow color, but do not touch the two blue rooms\nOutput: \nx_location, y_location, time_point\n-1.35, -1.1, 0\n-1.35, 1.1, 1\n-0.7, 1.1, 1.5\n\nInput:\navailable scene objects: [name : room1, color: cyan, function: Kitchen, position and size: (1.2, -0.8, 1.4, -0.7)], [name : room2, color: red, function: RestRoom2, position and size: (0, 0.9, 1.4, -0.7)], [name : room3, color: green, function: MasterBedroom, position and size: (-0.2, 1.43, -0.8, 1.43)], [name : room4, color: pink, function: Bedroom, position and size: (-0.6, 1.43, -0.2, 0.8)], [name : room5, color: blue, function: LivingRoom, position and size: (0.5, 0.5, 0.5, 0.5)], [name : room6, color: blue, function: ExerciseRoom, position and size: (1.2, -0.7, 0.05, 0.5)], [name : room7, color: yellow, function: RestRoom, position and size: (1.4, -0.2, -0.8, 1.43)], [name : room8, color: purple, function: DiningRoom, position and size: (0.7, -0.3, 1.4, -0.8)]\nStarting location: [-1.35, -1.1]\nEnding location: [1.15, 1.15]\nsentence: Reach one room closest to the center location and stay there for five seconds.\nOutput: \nx_location, y_location, time_point\n-1.35, -1.1, 0\n0.5, 0.5, 2\n0.5, 0.5, 7\n\nInput:\navailable scene objects: [name : room1, color: cyan, function: Kitchen, position and size: (1.2, -0.8, 1.4, -0.7)], [name : room2, color: red, function: RestRoom2, position and size: (0, 0.9, 1.4, -0.7)], [name : room3, color: green, function: MasterBedroom, position and size: (-0.2, 1.43, -0.8, 1.43)], [name : room4, color: pink, function: Bedroom, position and size: (-0.6, 1.43, -0.2, 0.8)], [name : room5, color: blue, function: LivingRoom, position and size: (0.5, 0.5, 0.5, 0.5)], [name : room6, color: blue, function: ExerciseRoom, position and size: (1.2, -0.7, 0.05, 0.5)], [name : room7, color: yellow, function: RestRoom, position and size: (1.4, -0.2, -0.8, 1.43)], [name : room8, color: purple, function: DiningRoom, position and size: (0.7, -0.3, 1.4, -0.8)]" 11 | prompt_end2end = part1 + '\nStarting location: ' + str(start_location_list) + '\nEnding location: ' + str(end_location_list) + '\nsentence: ' + sentence + 'Output: \nx_location, y_location, time_point' 12 | return prompt_end2end 13 | 14 | 15 | if domain == 'HouseWorld': 16 | for index in range(10): 17 | instruction_path = experiment_result_dir + '/HouseWorld/instr_dir' 18 | saving_path_test_case = experiment_result_dir + '/HouseWorld/' + model_name + '-end2end' 19 | if not os.path.exists(saving_path_test_case): 20 | os.mkdir(saving_path_test_case) 21 | 22 | saving_path = saving_path_test_case + '/sent' + str(index) 23 | if not os.path.exists(saving_path): 24 | os.mkdir(saving_path) 25 | with open(instruction_path + '/myfile_sent' + str(index+1) + '.txt', 'r') as file: 26 | input_instruction = file.read().split('\n\n') 27 | print('Length of different instructions of this kind is: ', len(input_instruction)) 28 | 29 | for i in range(len(input_instruction)): 30 | if len(input_instruction[i]) > 5: 31 | print('input_instruction' + str(i) + ': ', input_instruction[i]) 32 | if index == 8: 33 | prompt = end2end_prompt(input_instruction[i], [-1.35, -1.1],[1.15, 1.15]) 34 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 35 | with open(saving_path + '/myfile' + str(i) + '.txt', 36 | 'w') as f: 37 | # save your array into the file 38 | f.write(response) 39 | f.close() 40 | 41 | prompt = end2end_prompt(input_instruction[i], [-1.35, -0.6],[1.15, 1.35]) 42 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 43 | with open(saving_path + '/myfile' + str(i + 10) + '.txt', 44 | 'w') as f: 45 | # save your array into the file 46 | f.write(response) 47 | f.close() 48 | else: 49 | prompt = end2end_prompt(input_instruction[i], [random.uniform(1.2, 1.41), random.uniform(-1.2, -1.41)],[random.uniform(-0.2, 0.2), random.uniform(1.2, 1.41)]) 50 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 51 | with open(saving_path + '/myfile' + str(i) + '.txt', 52 | 'w') as f: 53 | # save your array into the file 54 | f.write(response) 55 | f.close() 56 | 57 | prompt = end2end_prompt(input_instruction[i], [random.uniform(-1.4, -0.6), random.uniform(-0.1, -0.6)],[random.uniform(-0.2, 0.2), random.uniform(1.2, 1.41)]) 58 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 59 | with open(saving_path + '/myfile' + str(i+10) + '.txt', 60 | 'w') as f: 61 | # save your array into the file 62 | f.write(response) 63 | f.close() 64 | elif domain == 'chip': 65 | for index in range(1): 66 | saving_path_test_case = experiment_result_dir + '/chip/' + model_name + '-end2end' 67 | if not os.path.exists(saving_path_test_case): 68 | os.mkdir(saving_path_test_case) 69 | instruction_path = experiment_result_dir + '/chip/instr_dir' 70 | saving_path = saving_path_test_case + '/sent' + str(index) 71 | if not os.path.exists(saving_path): 72 | os.mkdir(saving_path) 73 | with open(instruction_path + '/myfile_sent' + str(index+1) + '.txt', 'r') as file: 74 | input_instruction = file.read().split('\n\n') 75 | print('Length of different instructions of this kind is: ', len(input_instruction)) 76 | 77 | for i in range(len(input_instruction)): 78 | if len(input_instruction[i]) > 5: 79 | print('input_instruction' + str(i) + ': ', input_instruction[i]) 80 | 81 | prompt = end2end_prompt(input_instruction[i], 82 | [4.5 + random.uniform(-0.1, 0.1), 2 + random.uniform(-0.1, -0.1)], 83 | [1.15 + random.uniform(-0.1, 0.1), 1.15 + random.uniform(-0.1, 0.1)]) 84 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 85 | with open(saving_path + '/myfile' + str(i) + '.txt', 86 | 'w') as f: 87 | # save your array into the file 88 | f.write(response) 89 | f.close() 90 | 91 | prompt = end2end_prompt(input_instruction[i], 92 | [random.uniform(-1.4 + random.uniform(-0.1, 0.1), -0.6 + random.uniform(-0.1, 0.1)), random.uniform(-0.1 + random.uniform(-0.1, 0.1), -0.6 + random.uniform(-0.1, 0.1))], 93 | [random.uniform(-0.2 + random.uniform(-0.1, 0.1), 0.2 + random.uniform(-0.1, 0.1)), random.uniform(1.2 + random.uniform(-0.1, 0.1), 1.41 + random.uniform(-0.1, 0.1))]) 94 | response = GPT_response_first_round(prompt, model_name_NL2TL=model_name) 95 | with open(saving_path + '/myfile' + str(i + 10) + '.txt', 96 | 'w') as f: 97 | # save your array into the file 98 | f.write(response) 99 | f.close() 100 | -------------------------------------------------------------------------------- /openai_func.py: -------------------------------------------------------------------------------- 1 | # Note: you need to be using OpenAI Python v0.27.0 for the code below to work 2 | import openai 3 | import numpy as np 4 | import copy 5 | import ast 6 | import re 7 | import math 8 | 9 | openai_api_key_name = 'sk-...' # Register at https://beta.openai.com/ to get your API key 10 | 11 | def GPT_response_GPT_3(original_sent): 12 | openai.api_key = openai_api_key_name 13 | response = openai.Completion.create( 14 | model="text-davinci-003", 15 | prompt=original_sent, 16 | temperature=0.0, 17 | max_tokens=256, 18 | top_p=1, 19 | frequency_penalty=0, 20 | presence_penalty=0 21 | ) 22 | return response['choices'][0]['text'][1:] 23 | 24 | 25 | def GPT_response_first_round(user_prompt_1, model_name_NL2TL = 'gpt-4'): 26 | if model_name_NL2TL == 'gpt-4': 27 | openai.api_key = openai_api_key_name 28 | try: 29 | result = openai.ChatCompletion.create( 30 | model=model_name_NL2TL, 31 | messages=[ 32 | {"role": "system", "content": "You are a helpful assistant."}, 33 | {"role": "user", "content": user_prompt_1} 34 | ] 35 | ) 36 | except: 37 | result = openai.ChatCompletion.create( 38 | model=model_name_NL2TL, 39 | messages=[ 40 | {"role": "system", "content": "You are a helpful assistant."}, 41 | {"role": "user", "content": user_prompt_1} 42 | ] 43 | ) 44 | return result.choices[0]['message']['content'] 45 | elif model_name_NL2TL == 'gpt-3': 46 | openai.api_key = openai_api_key_name 47 | response = openai.Completion.create( 48 | model="text-davinci-003", 49 | prompt=user_prompt_1, 50 | temperature=0.0, 51 | max_tokens=256, 52 | top_p=1, 53 | frequency_penalty=0, 54 | presence_penalty=0 55 | ) 56 | return response['choices'][0]['text'][1:] 57 | 58 | def GPT_response_second_round(user_prompt_1, assistent_feed, user_prompt_2, model_name_NL2TL = 'gpt-4'): 59 | if model_name_NL2TL == 'gpt-4': 60 | openai.api_key = openai_api_key_name 61 | try: 62 | result = openai.ChatCompletion.create( 63 | model=model_name_NL2TL, 64 | messages=[ 65 | {"role": "system", "content": "You are a helpful assistant."}, 66 | {"role": "user", "content": user_prompt_1}, 67 | {"role": "assistant", "content": assistent_feed}, 68 | {"role": "user", "content": user_prompt_2} 69 | ] 70 | ) 71 | except: 72 | result = openai.ChatCompletion.create( 73 | model=model_name_NL2TL, 74 | messages=[ 75 | {"role": "system", "content": "You are a helpful assistant."}, 76 | {"role": "user", "content": user_prompt_1}, 77 | {"role": "assistant", "content": assistent_feed}, 78 | {"role": "user", "content": user_prompt_2} 79 | ] 80 | ) 81 | return result.choices[0]['message']['content'] 82 | 83 | elif model_name_NL2TL == 'gpt-3': 84 | openai.api_key = openai_api_key_name 85 | response = openai.Completion.create( 86 | model="text-davinci-003", 87 | prompt=user_prompt_1 + '\nGPT-3 response:\n' + assistent_feed + '\nHuman feedback:\n' + user_prompt_2, 88 | temperature=0.0, 89 | max_tokens=256, 90 | top_p=1, 91 | frequency_penalty=0, 92 | presence_penalty=0 93 | ) 94 | return response['choices'][0]['text'][1:] 95 | 96 | 97 | def GPT_NL2TL(lifted_NL, model_name_NL2TL = 'gpt-4'): 98 | NL2TL_prompt="Try to transform the following natural languages into signal temporal logics, the operators in the signal temporal logic are: negation, imply, and, equal, until, globally, finally, or . The time specification are integers larger or equal to 0, and use 'infinite' as the endless time.\nThe examples are as following:\nnatural language: If ( prop_2 ) is equivalent to ( prop_3 ) and also ( prop_4 ) , then the above scenario is equivalent to ( prop_1 ) .\nSTL: ( ( ( prop_2 equal prop_3 ) and prop_4 ) equal prop_1 )\n\nnatural language: For each time instant in the coming 145 to 584 time units either ( prop_1 ) or ( prop_2 ) should be detected , or else ( prop_3 ) .\nSTL: ( ( globally [145,584] ( prop_1 or prop_2 ) ) or prop_3 )\n\nnatural language: It is required that at a certain point within the next 317 to 767 time units the scenario in which ( prop_3 ) is equivalent to the scenario in which ( prop_2 ) happens , and only then ( prop_1 ) .\nSTL: ( ( finally [317,767] ( prop_3 equal prop_2 ) ) imply prop_1 )\n\nnatural language: In case that at some point ( prop_4 ) or ( prop_2 ) or ( prop_3 ) is detected and continued until then at some other point ( prop_1 ) should be detected as well .\nSTL: ( ( ( prop_4 or prop_2 ) or prop_3 ) until prop_1 )\n\nnatural language: ( prop_2 ) should happen and hold until at a certain time point during the 417 to 741 time units the scenario that ( prop_3 ) should happen then ( prop_1 ) , or else ( prop_4 ) .\nSTL: ( ( ( prop_2 until [417,741] prop_3 ) imply prop_1 ) or prop_4 )\n\nnatural language: For each time instant in the next 184 to 440 time units if it is not the case that ( prop_1 ) or ( prop_3 ) then ( prop_2 ) .\nSTL: ( ( globally [184,440] ( negation ( prop_1 or prop_3 ) ) ) imply prop_2 )\n\nnatural language: In case that ( prop_3 ) continues to happen until at some point during the first 391 to 525 time units that ( prop_2 ) happens , as well as ( prop_1 ) , and ( prop_4 ) then .\nSTL: ( ( ( prop_3 until [391,525] prop_2 ) and prop_1 ) and prop_4 )\n\nnatural language: If finally that ( prop_1 ) is not detected then ( prop_2 ) , then ( prop_3 ) .\nSTL: ( ( ( finally ( negation prop_1 ) ) imply prop_2 ) imply prop_3 )\n\nnatural language: It is not the case that ( prop_1 ) if and only if ( prop_2 ) is true , the above scenario will hold until ( prop_3 ) will be detected at some time point during the next 394 to 530 time units .\nSTL: ( ( negation ( prop_1 equal prop_2 ) ) until [394,530] prop_3 )\n\nnatural language: If at some point ( prop_1 ) or ( prop_3 ) then ( prop_4 ) happens and this scenario will hold until at some other point during the 193 to 266 time units ( prop_2 ) is detected .\nSTL: ( ( ( prop_1 or prop_3 ) imply prop_4 ) until [193,266] prop_2 )\n\nnatural language: It is not the case that ( prop_1 ) happens and continues to happen until at some point during the 77 to 432 time units ( prop_2 ) is detected , and ( prop_3 ) .\nSTL: ( ( negation ( prop_1 until [77,432] prop_2 ) ) and prop_3 )\n\nnatural language: ( prop_3 ) happens until a time in the next 5 to 12 units that ( prop_4 ) does not happen .\nSTL: ( prop_3 until [5,12] ( negation prop_4 ) )\n\nnatural language: The time that ( prop_3 ) happens is when ( prop_1 ) happens , and vice versa .\nSTL: ( prop_3 equal prop_1 )\n\nnatural language: It is required that both ( prop_2 ) and ( prop_4 ) happen at the same time, or else ( prop_3 ) happens and continues until ( prop_1 ) happens.\nSTL: ( ( prop_2 and prop_4 ) or ( prop_3 until prop_1 ) )\n\nnatural language: ( prop_3 ) happens and continues until at some point during the 500 to 903 time units ( prop_1 ) happens , and in the same time ( prop_2 ) does not happen .\nSTL: ( ( prop_3 until [500,903] prop_1 ) and ( negation prop_2 ) )\n\nnatural language: For each time instant in the next 107 to 513 time units ( prop_1 ) is true , or else ( prop_3 ) happens and ( prop_2 ) happens at the same time.\nSTL: ( ( globally [107,513] prop_1 ) or ( prop_3 and prop_2 ) )\n\nnatural language: ( prop_1 ) or ( prop_2 ) happens and continues until at some point during the 142 to 365 time units ( prop_4 ) happens and ( prop_3 ) happens at the same time .\nSTL: ( ( prop_1 or prop_2 ) until [142,365] ( prop_4 and prop_3 ) )\n\nnatural language: It is always the case that everytime when ( prop_1 ) and ( prop_2 ) then all of the following conditions hold : for each time point during the subsequent 4 to 47 time units ( prop_3 ) .\nSTL: globally ( ( prop_1 and prop_2 ) imply ( globally [4,47] prop_3 ) )\n\nnatural language: at some time ( prop_1 ) and when possible ( prop_2 )\nSTL: finally ( prop_1 and finally prop_2 )\n\nnatural language: at some time ( prop_1 ) and never ( prop_2 )\nSTL: ( finally prop_1 ) and ( globally ( negation prop_2 ) )\n\nnatural language: when possible ( prop_1 ) and at some time ( prop_2 )\nSTL: finally ( prop_1 and ( finally prop_2 ) )\n\nnatural language: never ( prop_1 ) or whenever ( prop_2 )\nSTL: ( globally ( ( negation prop_1 ) ) or ( finally prop_2 ) )\n\nnatural language: when possible ( prop_1 ) and don't ( prop_2 )\nSTL: finally ( prop_1 and ( negation prop_2 ) )\n\nnatural language: ( prop_1 ) or at any time ( prop_2 )\nSTL: ( prop_1 or ( finally prop_2 ) )\n\nnatural language: Globally , if ( prop_1 ) then the following condition is true : at the same time the event that ( prop_2 ) ought to be detected and ( prop_3 ) .\nSTL: globally ( prop_1 imply ( prop_2 and prop_3 ) )\n\nnatural language: at some time ( prop_1 ) or ( prop_2 )\nSTL: finally ( prop_1 or prop_2 )\n\nnatural language: ( prop_1 ) and at some time ( prop_2 )\nSTL: ( prop_1 and ( finally prop_2 ) )\n\nnatural language: whenever ( prop_1 ) and at any time ( prop_2 )\nSTL: ( ( finally prop_1 ) and ( finally prop_2 ) )\n\nnatural language: whenever ( prop_1 ) or forever ( prop_2 )\nSTL: ( ( finally prop_1 ) or ( globally prop_2 ) )\n\nnatural language: At the random time between 0 to 30 (prop_1) for 5 seconds, and at the random time between 0 to 30 (prop_2) for 5 seconds, and at the random time between 0 to 30 (prop_3) for 5 seconds.\nSTL: ( ( ( finally [0,30] ( globally [0,5] prop_1 ) ) and ( finally [0,30] ( globally [0,5] prop_2 ) ) ) and ( finally [0,30] ( globally [0,5] prop_3 ) ) )\n\nnatural language: At sometime between 1 to 25 stay at prop_1 for five seconds and always stay away from the prop_2 and prop_3 during 0 to 30 seconds.\nSTL: ( ( finally [1,25] ( globally [0,5] prop_1 ) ) and ( globally [0,30] ( negation prop_2 and negation prop_3 ) ) )\n\nnatural language: Always (prop_1) if not (prop_2).\nSTL: ( ( negation prop_2 ) imply ( globally prop_1 ) )\n\nnatural language: Always (prop_1) only if not (prop_2).\nSTL: ( (globally prop_1 ) imply ( negation prop_2 ) )\n\nnatural language: Avoid (prop_1) until (prop_2) lasts for 20 steps.\nSTL: ( ( negation prop_1 ) until ( globally [0, 20] prop_2 ) )\n\nnatural language: Wait till (prop_1) is complete, then, (prop_2) for next 20 units.\nSTL: ( ( finally prop_1 ) imply ( globally [0, 20] prop_2 ) )\n\nnatural language: ( prop_1 ) won't happen only if ( prop_2 )\nSTL: ( ( negation prop_1 ) imply prop_2 )\n\nnatural language: only under the case of ( prop_2 ), will ( prop_1 ) not happen\nSTL: ( ( negation prop_1 ) imply prop_2 )\n\nnatural language: ( prop_1 ) always follows with ( prop_2 ).\nSTL: ( globally ( prop_1 imply ( finally prop_2 ) ) )\n\nnatural language: Maintain ( prop_1 ) until ( prop_2 ) is satisfied.\nSTL: globally ( prop_1 until prop_2 )\n\nnatural language: Go to ( prop_1 ) and always avoid both ( prop_2 ) and ( prop_3 ).\nSTL: ( ( finally prop_1 ) and globally ( ( negation prop_2 ) and ( negation prop_3 ) ) )\n\nnatural language: If ( prop_1 ) happens before ( prop_3 ) then start ( prop_2 ) and cancel ( prop_4 ) anytime within 0 to 10 timesteps.\nSTL: globally ( ( prop_1 and ( finally prop_3 ) ) imply ( prop_2 and ( finally [0,10] ( negation prop_4 ) ) ) )\n\nnatural language: For time steps between 0 and 20, until (prop_1) and (prop_2) is true, don’t start ( prop_3 ).\nSTL: ( globally [0,20] ( ( negation prop_3 ) until ( prop_1 and prop_2 ) ) )\n\nnatural language: If prop_1 and prop_2 and not prop_3 or prop_4, then prop_5 happens after 10 timesteps.\nSTL: ( ( prop_1 and prop_2 ) and ( negation ( prop_3 or prop_4 ) ) ) imply ( finally [10,infinite] prop_5 )\n\nnatural language: prop_1 for the first 5 timesteps then prop_2 thereafter.\nSTL: ( ( globally [0,5] prop_1 ) and ( globally [5,infinite] prop_2 ) )\n\nnatural language: prop_1 and prop_2 and prop_3 and prop_4 and prop_5\nSTL: ( ( ( ( prop_1 and prop_2 ) and prop_3 ) and prop_4 ) and prop_5 )\n\nnatural language: prop_1 and prop_2 and prop_3\nSTL: ( ( prop_1 and prop_2 ) and prop_3 )\n\nnatural language: " 99 | 100 | if model_name_NL2TL == 'gpt-4': 101 | openai.api_key = openai_api_key_name 102 | result = openai.ChatCompletion.create( 103 | model=model_name_NL2TL, 104 | messages=[ 105 | {"role": "system", "content": "You are a helpful assistant."}, 106 | {"role": "user", "content": NL2TL_prompt + lifted_NL + '\nSTL: '} 107 | ] 108 | ) 109 | return result.choices[0]['message']['content'] 110 | elif model_name_NL2TL == 'gpt-3': 111 | openai.api_key = openai_api_key_name 112 | response = openai.Completion.create( 113 | model="text-davinci-003", 114 | prompt=NL2TL_prompt + lifted_NL + '\nSTL: ', 115 | temperature=0.0, 116 | max_tokens=256, 117 | top_p=1, 118 | frequency_penalty=0, 119 | presence_penalty=0 120 | ) 121 | return response['choices'][0]['text'][1:] 122 | 123 | def GPT_NL2TL_preorder(lifted_NL, model_name_NL2TL = 'gpt-4'): 124 | NL2TL_prompt="Try to transform the following natural languages into signal temporal logics, the operators in the signal temporal logic are: negation, imply, and, equal, until, globally, finally, or .\nThe signal temporal logics are prefix expressions. The examples are as following:\nnatural language: If ( prop_3 ) then implies ( prop_4 ), this condition should continue to happen until at some point within the next 450 to 942 time units , after that ( prop_2 ) , or ( prop_1 ) .\nSTL: ['or', 'until [450,942]', 'imply', 'prop_3', 'prop_4', 'prop_2', 'prop_1']\n\nnatural language: The time that ( prop_3 ) happens is when ( prop_1 ) happens , and vice versa .\nSTL: ['equal', 'prop_3', 'prop_1']\n\nnatural language: ( prop_1 ) or ( prop_2 ) happens and continues until at some point during the 142 to 365 time units ( prop_4 ) happens and ( prop_3 ) happens at the same time .\nSTL: ['until [142,365]', 'or', 'prop_1', 'prop_2', 'and', 'prop_4', 'prop_3']\n\nnatural language: ( prop_1 ) should not happen and ( prop_2 ) should happen at the same time , and the above scenario is equivalent to the case that at some point during the 230 to 280 time units ( prop_3 ) happens .\nSTL: ['equal', 'and', 'negation', 'prop_1', 'prop_2', 'finally [230,280]', 'prop_3']\n\nnatural language: In the following 10 time steps , the ( prop_1 ) should always happen , and in the meantime , ( prop_2 ) should happen at least once .\nSTL: ['and', 'globally [0,10]', 'prop_1', 'finally', 'prop_2']\n\nnatural language: ( prop_1 ) should not happen if ( prop_2 ) does not happen , and ( prop_3 ) should also be true all the time .\nSTL: ['and', 'imply', 'negation', 'prop_2', 'negation', 'prop_1', 'globally', 'prop_3']\n\nnatural language: If ( prop_1 ) and ( prop_2 ), then ( prop_3 ) until ( prop_4 ) does not happen , and ( prop_5 ) until ( prop_6 ) does not happen .\nSTL: ['and', 'imply', 'and', 'prop_1', 'prop_2', 'until', 'prop_3', 'negation', 'prop_4', 'until', 'prop_5', 'negation', 'prop_6']\n\nnatural language: For each time instant in the next 0 to 120 units, do ( prop_1 ) if ( prop_2 ) , and if possible, ( prop_4 ) .\nSTL: ['and', 'globally [0,120]', 'imply', 'prop_2', 'prop_1', 'prop_4']\n\nnatural language: In the next 0 to 5 time units , do the ( prop_1 ) , but in the next 3 to 4 time units , ( prop_2 ) should not happen .\nSTL: ['and', 'globally [0,5]', 'prop_1', 'globally [3,4]', 'negation', 'prop_2']\n\nnatural language: While (prop_1) , do (prop_2) , and when (prop_3) , stop (prop_2) .\nSTL: ['and', 'imply', 'prop_1', 'prop_2', 'imply', 'prop_3', 'negation', 'prop_2']\n\nnatural language: If (prop_1) happens, then some time after the next 300 time steps (prop_2) should happen.\nSTL: ['imply', 'prop_1', 'finally [300, infinite]', 'prop_2']\n\nnatural language: If (prop_1) happens, then for all time afterward (prop_2) holds and if, in addition, if (prop_3) occurs, then (prop_4) eventually occurs in the next 10 time units.\nSTL: ['imply', 'prop_1', 'and', 'globally', 'prop_2', 'imply', 'prop_3', 'finally [0, 10]', 'prop_4']\n\nnatural language: If (prop_1), don't (prop_2), instead keep (prop_3) until (prop_4).\nSTL: ['imply', 'prop_1', 'and', 'negation', 'prop_2', 'until', 'prop_3', 'prop_4']\n\nnatural language: If (prop_4), then make sure any of the following happens: (prop_1), (prop_2) or (prop_3).\nSTL: ['imply', 'prop_4', 'or', 'or', 'prop_1', 'prop_2', 'prop_3']\n\nnatural language: Always make (prop_1) happen in the next 999 time units if (prop_2) in the next 500 time instants.\nSTL: ['imply', 'finally [0, 500]', 'prop_2', 'finally [0, 999]', 'prop_1']\n\nnatural language: If (prop_1) happens, then keep (prop_2) to be true until (prop_3) in the next 300 time units, otherwise, if (prop_4) then (prop_2) and if (prop_5) then (prop_6).\nSTL: ['imply', 'prop_1', 'or', 'until [0, 300]', 'prop_2', 'prop_3', 'and', 'imply', 'prop_4', 'prop_2', 'imply', 'prop_5', 'prop_6']\n\nnatural language: Stay (prop_1) for 354 timesteps, and if (prop_2) happens, then first keep (prop_3) and then let (prop_4) happen at some point during 521 to 996 time steps.\nSTL: ['and', 'globally [0, 354]', 'prop_1', 'imply', 'prop_2', 'and', 'globally [0, 521]', 'prop_3', 'finally [521, 996]', 'prop_4']\n\nnatural language: Manage to achieve (prop_1) in the next 1000 time steps, and if (prop_2) happens in this process, keep (prop_3) until (prop_4) for 500 time units.\nSTL: ['and', 'finally [0, 1000]', 'prop_1', 'imply', 'prop_2', 'until [0, 500]', 'prop_3', 'prop_4']\n\nnatural language: As long as (prop_1), make sure to maintain (prop_2) .\nSTL: ['imply', 'prop_1', 'prop_2']\n\nnatural language: Do (prop_1) until (prop_3), but once (prop_4) occurs then immediately (prop_2) .\nSTL: ['and', 'until', 'prop_3', 'prop_1', 'imply', 'prop_4', 'prop_2']\n\nnatural language: If you do (prop_1) and observe (prop_2), then you should not do (prop_3) .\nSTL: ['imply', 'and', 'prop_1', 'prop_2', 'negation', 'prop_3']\n\nnatural language: The time that ( prop_3 ) happens is when ( prop_1 ) happens , and vice versa .\nSTL: ['equal', 'prop_1', 'prop_2']\n\nnatural language: It is required that both ( prop_2 ) and ( prop_4 ) happen at the same time, or else ( prop_3 ) happens and continues until ( prop_1 ) happens.\nSTL: ['or', 'and', 'prop_2', 'prop_4', 'until', 'prop_3', 'prop_1']\n\nnatural language: ( prop_3 ) happens and continues until at some point during the 500 to 903 time units ( prop_1 ) happens , and in the same time ( prop_2 ) does not happen .\nSTL: ['and', 'until [500,903]', 'prop_3', 'prop_1', 'negation', 'prop_2']\n\nnatural language: For each time instant in the next 107 to 513 time units ( prop_1 ) is true , or else ( prop_3 ) happens and ( prop_2 ) happens at the same time.\nSTL: ['or', 'globally [107, 513]', 'prop_1', 'and', 'prop_3', 'prop_2']\n\nnatural language: ( prop_1 ) or ( prop_2 ) happens and continues until at some point during the 142 to 365 time units ( prop_4 ) happens and ( prop_3 ) happens at the same time .\nSTL: ['until [142,365]', 'or', 'prop_1', 'prop_2', 'and', 'prop_4', 'prop_3']\n\nnatural language: It is always the case that everytime when ( prop_1 ) and ( prop_2 ) then all of the following conditions hold : for each time point during the subsequent 4 to 47 time units ( prop_3 ) .\nSTL: ['imply', 'and', 'prop_1', 'prop_2', 'globally [4,47]', 'prop_3']\n\nnatural language: at some time ( prop_1 ) and when possible ( prop_2 )\nSTL: ['and', 'prop_1', 'finally', 'prop_2']\n\nnatural language: at some time ( prop_1 ) and never ( prop_2 )\nSTL: ['and', 'finally', 'prop_1', 'globally', 'negation', 'prop_2']\n\nnatural language: when possible ( prop_1 ) and at some time ( prop_2 )\nSTL: ['finally', 'and', 'prop_1', 'finally', 'prop_2']\n\nnatural language: never ( prop_1 ) or whenever ( prop_2 )\nSTL: ['or', 'globally', 'negation', 'prop_1', 'finally', 'prop_2']\n\nnatural language: when possible ( prop_1 ) and don't ( prop_2 )\nSTL: ['finally', 'and', 'prop_1', 'negation', 'prop_2']\n\nnatural language: ( prop_1 ) or at any time ( prop_2 )\nSTL: ['or', 'prop_1', 'finally', 'prop_2']\n\nnatural language: Globally , if ( prop_1 ) then the following condition is true : at the same time the event that ( prop_2 ) ought to be detected and ( prop_3 ) .\nSTL: ['globally', 'imply', 'prop_1', 'and', 'prop_2', 'prop_3']\n\nnatural language: at some time ( prop_1 ) or ( prop_2 )\nSTL: ['finally', 'or', 'prop_1', 'prop_2']\n\nnatural language: ( prop_1 ) and at some time ( prop_2 )\nSTL: ['and', 'prop_1', 'finally', 'prop_2']\n\nnatural language: whenever ( prop_1 ) and at any time ( prop_2 )\nSTL: ['and', 'finally', 'prop_1', 'finally', 'prop_2']\n\nnatural language: whenever ( prop_1 ) or forever ( prop_2 )\nSTL: ['or', 'finally', 'prop_1', 'globally', 'prop_2']\n\nnatural language: At the random time between 0 to 30 (prop_1) for 5 seconds, and at the random time between 0 to 30 (prop_2) for 5 seconds, and at the random time between 0 to 30 (prop_3) for 5 seconds.\nSTL: ['and', 'and', 'finally [0,30]', 'globally [0,5]', 'prop_1', 'finally [0,30]', 'globally [0,5]', 'prop_2', 'finally [0,30]', 'globally [0,5]', 'prop_3']\n\nnatural language: At sometime between 1 to 25 stay at prop_1 for five seconds and always stay away from the prop_2 and prop_3 during 0 to 30 seconds.\nSTL: ['and', 'finally [1,25]', 'globally [0,5]', 'prop_1', 'globally [0,30]', 'and', 'negation', 'prop_2', 'negation', 'prop_3']\n\nnatural language: Always (prop_1) if not (prop_2).\nSTL: ['imply', 'negation', 'prop_2', 'globally', 'prop_1']\n\nnatural language: Always (prop_1) only if not (prop_2).\nSTL: ['imply', 'globally', 'prop_1', 'negation', 'prop_2']\n\nnatural language: Avoid (prop_1) until (prop_2) lasts for 20 steps.\nSTL: ['until', 'negation', 'prop_1', 'globally [0, 20]', 'prop_2']\n\nnatural language: Wait till (prop_1) is complete, then, (prop_2) for next 20 units.\nSTL: ['imply', 'finally', 'prop_1', 'globally [0, 20]', 'prop_2']\n\nnatural language: ( prop_1 ) won't happen only if ( prop_2 )\nSTL: ['imply', 'negation', 'prop_1', 'prop_2']\n\nnatural language: only under the case of ( prop_2 ), will ( prop_1 ) not happen\nSTL: ['imply', 'negation', 'prop_1', 'prop_2']\n\nnatural language: ( prop_1 ) always follows with ( prop_2 ).\nSTL: ['globally', 'imply', 'prop_1', 'finally', 'prop_2']\n\nnatural language: Maintain ( prop_1 ) until ( prop_2 ) is satisfied.\nSTL: ['globally', 'until', 'prop_1', 'prop_2']\n\nnatural language: Go to ( prop_1 ) and always avoid both ( prop_2 ) and ( prop_3 ).\nSTL: ['and', 'finally', 'prop_1', 'globally', 'and', 'negation', 'prop_2', 'negation', 'prop_3']\n\nnatural language: If ( prop_1 ) happens before ( prop_3 ) then start ( prop_2 ) and cancel ( prop_4 ) anytime within 0 to 10 timesteps.\nSTL: ['globally', 'imply', 'and', 'prop_1', 'finally', 'prop_3', 'and', 'prop_2', 'finally', 'negation', 'prop_4']\n\nnatural language: For time steps between 0 and 20, until (prop_1) and (prop_2) is true, don’t start ( prop_3 ).\nSTL: ['globally [0,20]', 'until', 'negation', 'prop_3', 'and', 'prop_1', 'prop_2']\n\nnatural language: If prop_1 and prop_2 and not prop_3 or prop_4, then prop_5 happens after 10 timesteps.\nSTL: ['imply', 'and', 'and', 'prop_1', 'prop_2', 'negation', 'or', 'prop_3', 'prop_4', 'finally [10,infinite]', 'prop_5']\n\nnatural language: prop_1 for the first 5 timesteps then prop_2 thereafter.\nSTL: ['and', 'globally [0,5]', 'prop_1', 'globally [5,infinite]', 'prop_2']\n\nnatural language: prop_1 and prop_2 and prop_3 and prop_4 and prop_5\nSTL: ['and', 'and', 'and', 'and', 'prop_1', 'prop_2', 'prop_3', 'prop_4', 'prop_5']\n\nnatural language: prop_1, then prop_2 and stay there for 5 seconds, remember always prop_3.\nSTL: ['and', 'finally', 'prop_1', 'and', 'finally', 'globally [0,5]', 'prop_2', 'globally', 'prop_3']\n\nnatural language: " 125 | 126 | if model_name_NL2TL == 'gpt-4': 127 | openai.api_key = openai_api_key_name 128 | try: 129 | result = openai.ChatCompletion.create( 130 | model=model_name_NL2TL, 131 | messages=[ 132 | {"role": "system", "content": "You are a helpful assistant."}, 133 | {"role": "user", "content": NL2TL_prompt + lifted_NL + '\nSTL: '} 134 | ] 135 | ) 136 | except: 137 | result = openai.ChatCompletion.create( 138 | model=model_name_NL2TL, 139 | messages=[ 140 | {"role": "system", "content": "You are a helpful assistant."}, 141 | {"role": "user", "content": NL2TL_prompt + lifted_NL + '\nSTL: '} 142 | ] 143 | ) 144 | return result.choices[0]['message']['content'] 145 | elif model_name_NL2TL == 'gpt-3': 146 | openai.api_key = openai_api_key_name 147 | response = openai.Completion.create( 148 | model="text-davinci-003", 149 | prompt=NL2TL_prompt + lifted_NL + '\nSTL: ', 150 | temperature=0.0, 151 | max_tokens=256, 152 | top_p=1, 153 | frequency_penalty=0, 154 | presence_penalty=0 155 | ) 156 | return response['choices'][0]['text'][1:] 157 | 158 | def parse_string(input_string): 159 | # Split the string into sentence and properties part 160 | parts = re.split('\s*:\s*', input_string, 1) 161 | 162 | try: 163 | # Get the sentence part 164 | sentence = parts[1].split('.', 1)[0].strip() + '.' 165 | 166 | # Get the properties part 167 | properties = parts[1].split('.', 1)[1].strip() 168 | except: 169 | # Get the sentence part 170 | sentence = parts[1].split('\n')[0].strip() 171 | 172 | # Get the properties part 173 | properties = parts[1].split('\n')[1].strip() 174 | 175 | # Remove white spaces and split properties by ';' 176 | property_list = re.split('\s*;\s*', properties) 177 | 178 | # Remove the last empty element if it exists 179 | if property_list[-1] == '': 180 | property_list = property_list[:-1] 181 | 182 | # Prepare property dictionary 183 | prop_dict = {} 184 | for prop in property_list: 185 | # Split property by ':' 186 | key_value = re.split('\s*:\s*', prop) 187 | 188 | # Remove the first and the last characters (which are quotes) from the key 189 | key = key_value[0][1:-1] 190 | 191 | # Remove the first and the last characters (which are brackets and quotes) from the values 192 | # and split the values by ',' but considering 'finally [0,10]' as a single entity 193 | values = re.findall(r"'[^']*'|\"[^\"]*\"", key_value[1]) 194 | values = [v[1:-1] for v in values] 195 | 196 | # Assign values to corresponding key in the dictionary 197 | prop_dict[key] = values 198 | 199 | return sentence, prop_dict 200 | 201 | 202 | def AP_dict_func(AP_specify): 203 | AP_dict = {} 204 | for item in AP_specify: 205 | action_list = item.split(' : ')[1][1:-1].split(', ') 206 | if len(action_list) < 1: 207 | print('Error! action len in ' + item.split(' : ')[0] + ' is zero!') 208 | else: 209 | for index in range(len(action_list)): 210 | if index == 0: 211 | action_TL = action_list[index] 212 | else: 213 | action_TL = '( ' + action_TL + ' and ' + action_list[index] + ' )' 214 | 215 | AP_dict[item.split(' : ')[0]] = action_TL 216 | return AP_dict 217 | 218 | def AP_dict_func_preorder(AP_specify): 219 | AP_dict = {} 220 | for item in AP_specify: 221 | item_process = item.split(' : ') 222 | if len(item_process) != 2: 223 | item_process = item.split(': ') 224 | action_list = item_process[1][1:-1].split(', ') 225 | action_list = [item[1:-1] for item in action_list] 226 | if len(action_list) < 1: 227 | print('Error! action len in ' + item.split(' : ')[0] + ' is zero!') 228 | else: 229 | if len(item_process) == 2: 230 | AP_dict[item.split(' : ')[0][1:-1]] = action_list 231 | else: 232 | AP_dict[item.split(': ')[0][1:-1]] = action_list 233 | return AP_dict 234 | 235 | def is_unary_operator(token): 236 | return token in ('negation', 'globally', 'finally') or token.split(' ')[0] in ('globally', 'finally', 'negation') 237 | 238 | def is_operator(token): 239 | return token in ('and', 'imply', 'equal', 'or', 'until', 'negation', 'globally', 'finally') \ 240 | or token.split(' ')[0] in ('globally', 'finally', 'until') 241 | 242 | def check_syntactic_correct(converted_list): 243 | count = 0 244 | for item in converted_list: 245 | if is_operator(item): 246 | if is_unary_operator(item): 247 | pass 248 | else: 249 | count -= 1 250 | elif item[:4] == 'prop' or item[:5] == 'enter' or item[:4] == 'not_': 251 | count += 1 252 | else: 253 | return item 254 | if count == 1: 255 | return 'correct' 256 | else: 257 | return count 258 | 259 | def check_syntactic_correct_inverse_order(converted_list_input): 260 | converted_list = copy.deepcopy(converted_list_input) 261 | converted_list.reverse() 262 | count = 0 263 | for item in converted_list: 264 | if is_operator(item): 265 | if is_unary_operator(item): 266 | pass 267 | else: 268 | count -= 1 269 | if count == 0: 270 | return 'error' 271 | elif item[:4] == 'prop' or item[:5] == 'enter' or item[:4] == 'not_': 272 | count += 1 273 | if count == 0: 274 | return 'error' 275 | else: 276 | return 'error' 277 | if count == 1: 278 | return 'correct' 279 | else: 280 | return 'error' 281 | 282 | def AP_dict_syntactic_correct_check(AP_dict): 283 | for prop_tag, prop_list in AP_dict.items(): 284 | if check_syntactic_correct(prop_list) != 'correct': 285 | return False 286 | return True 287 | 288 | def func_syntactic_correct_loop(model_name, user_prompt_1, AP_and_lifted_NL): 289 | lifted_NL, AP_dict = parse_string(AP_and_lifted_NL) 290 | for i in range(5): 291 | if AP_dict_syntactic_correct_check(AP_dict) == False: 292 | print('\nSyntactic loop' + str(i + 1) + ':\n') 293 | if model_name == 'gpt-3': 294 | user_prompt_syntactic_correct = user_prompt_1 + '\nGPT-3 response:\n' + AP_and_lifted_NL + '\nHuman feedback: ' 295 | for prop_tag, prop_list in AP_dict.items(): 296 | if check_syntactic_correct(prop_list) != 'correct' and type(check_syntactic_correct(prop_list)) == int: 297 | if check_syntactic_correct(prop_list) > 1: 298 | user_prompt_syntactic_correct += 'Your predicted ' + prop_tag + ' lacks ' + str(check_syntactic_correct(prop_list) - 1) + ' operators with two leaves, the correct syntactic format should be like '\ 299 | + str(['and']*(check_syntactic_correct(prop_list) - 1) + prop_list) + '. ' 300 | elif check_syntactic_correct(prop_list) < 1: 301 | user_prompt_syntactic_correct += 'Your predicted ' + prop_tag + ' has ' + str(1 - check_syntactic_correct(prop_list)) + ' more operators with two leaves, the correct syntactic format should be like '\ 302 | + str(prop_list[abs(check_syntactic_correct(prop_list)-1):]) + '. ' 303 | 304 | user_prompt_syntactic_correct += 'Please correct your answer with the same format as the previous output.\nOutput: ' 305 | AP_and_lifted_NL = GPT_response_GPT_3(user_prompt_syntactic_correct) 306 | lifted_NL, AP_dict = parse_string(AP_and_lifted_NL) 307 | 308 | for prop_tag, prop_list in AP_dict.items(): 309 | print(prop_tag + ': ' + str(prop_list)) 310 | elif model_name == 'gpt-4': 311 | assistent_feed = copy.deepcopy(AP_and_lifted_NL) 312 | user_prompt_2 = '' 313 | for prop_tag, prop_list in AP_dict.items(): 314 | if check_syntactic_correct(prop_list) != 'correct' and type(check_syntactic_correct(prop_list)) == int: 315 | if check_syntactic_correct(prop_list) > 1: 316 | user_prompt_2 += 'Your predicted ' + prop_tag + ' lacks ' + str(check_syntactic_correct(prop_list) - 1) + ' operators with two leaves, the correct syntactic format should be like '\ 317 | + str(['and']*(check_syntactic_correct(prop_list) - 1) + prop_list) + '. ' 318 | elif check_syntactic_correct(prop_list) < 1: 319 | user_prompt_2 += 'Your predicted ' + prop_tag + ' has ' + str(1 - check_syntactic_correct(prop_list)) + ' more operators with two leaves, the correct syntactic format should be like '\ 320 | + str(prop_list[abs(check_syntactic_correct(prop_list)-1):]) + '. ' 321 | 322 | user_prompt_2 += 'Please correct your answer.\nOutput: ' 323 | AP_and_lifted_NL = GPT_response_second_round(user_prompt_1, assistent_feed, user_prompt_2) 324 | lifted_NL, AP_dict = parse_string(AP_and_lifted_NL) 325 | 326 | for prop_tag, prop_list in AP_dict.items(): 327 | print(prop_tag + ': ' + str(prop_list)) 328 | else: 329 | return AP_and_lifted_NL, i+1 330 | return AP_and_lifted_NL, i+1 331 | 332 | def trajectory_len_cal(PWLs): 333 | trajectory_len = 0 334 | for i in range(len(PWLs)): 335 | PWL = PWLs[i] 336 | position_list = [[P[0][0], P[0][1]] for P in PWL] 337 | for i in range(len(position_list)-1): 338 | trajectory_len += np.sqrt((position_list[i][0]-position_list[i+1][0])**2 + (position_list[i][1]-position_list[i+1][1])**2) 339 | 340 | return trajectory_len 341 | 342 | 343 | def state_check(PWL_x_y_t, tag_and_shape): 344 | for color, block_array in tag_and_shape.items(): 345 | B_item = [] 346 | for block_item_list in block_array: 347 | block_item = block_item_list[:-1] 348 | block_item_func_str = block_item_list[-1] 349 | if PWL_x_y_t[0] > -block_item[0] and PWL_x_y_t[0] < block_item[1] and PWL_x_y_t[1] > -block_item[2] and PWL_x_y_t[ 350 | 1] < block_item[3]: 351 | return color, block_item_func_str, block_item 352 | return 'white', 'road', None 353 | 354 | 355 | def interpolate_list(data, divide_path_time_ratio): 356 | # Ensure divide_path_time_ratio is a power of 2 357 | if (divide_path_time_ratio & (divide_path_time_ratio - 1)) != 0 or divide_path_time_ratio == 0: 358 | raise ValueError("divide_path_time_ratio must be a power of 2.") 359 | 360 | # Copy the original data 361 | new_data = list(data) 362 | 363 | # Loop for log2(divide_path_time_ratio) times 364 | for _ in range(int(math.log2(divide_path_time_ratio))): 365 | # Temporary list to store new data 366 | temp_data = [] 367 | for i in range(len(new_data) - 1): 368 | # Calculate mid-point and add it to the temporary list 369 | mid_point = [(new_data[i][j] + new_data[i + 1][j]) / 2 for j in range(len(new_data[i]))] 370 | temp_data.append(new_data[i]) 371 | temp_data.append(mid_point) 372 | temp_data.append(new_data[-1]) 373 | # Update new_data 374 | new_data = list(temp_data) 375 | return new_data 376 | 377 | 378 | def judge_trajectory_output_state(tag_and_shape, PWL, divide_path_time_ratio=1): 379 | state_time_list = [] 380 | if len(PWL) > 3: 381 | PWL_new = interpolate_list(PWL, divide_path_time_ratio) 382 | for item in PWL_new: 383 | color, block_item_func_str, block_item = state_check(item, tag_and_shape) 384 | if block_item is not None: 385 | state_time_list.append([color, block_item_func_str, str(item[-1])]) 386 | else: 387 | state_time_list.append(['white', 'road', str(item[-1])]) 388 | # pass 389 | elif len(PWL) == 3: 390 | print('The STL is semantically impractical to plan out a trajectory.') 391 | pass 392 | #except: 393 | # print('The STL is syntactically impractical to plan out a trajectory.') 394 | return state_time_list 395 | 396 | 397 | def abbreviate_list_state_check(lst): 398 | result = [] 399 | temp_group = [] 400 | 401 | for i in range(len(lst)): 402 | if temp_group and (lst[i][:2] != temp_group[0][:2]): 403 | # Append the first and last element of the temp_group to the result list, if they're different 404 | if temp_group[0] != temp_group[-1]: 405 | result.append(temp_group[0]) 406 | result.append(temp_group[-1]) 407 | else: 408 | result.append(temp_group[0]) 409 | # Clear the temp_group 410 | temp_group = [] 411 | # Append the current element to the temp_group 412 | temp_group.append(lst[i]) 413 | 414 | # Append the first and last element of the last group, if they're different 415 | if temp_group: 416 | if temp_group[0] != temp_group[-1]: 417 | result.append(temp_group[0]) 418 | result.append(temp_group[-1]) 419 | else: 420 | result.append(temp_group[0]) 421 | 422 | return result 423 | 424 | 425 | def extract_list_for_semantic_check_LLM_response(s): 426 | match = re.search(r'STL:\s*\[(.*?)\]', s) 427 | if match: 428 | # Splitting the matched group by comma and stripping leading/trailing whitespaces 429 | extracted_list = [item.strip().strip("'") for item in match.group(1).split(',')] 430 | return extracted_list 431 | else: 432 | return [] 433 | 434 | def filter_negation_imply(input_stl_original): 435 | input_stl = copy.deepcopy(input_stl_original) 436 | # filter imply operation 437 | for index_negation in range(len(input_stl) - 1, -1, -1): 438 | if input_stl[index_negation] == 'imply': 439 | input_stl.pop(index_negation) 440 | input_stl.insert(index_negation, 'or') 441 | input_stl.insert(index_negation + 1, 'negation') 442 | # filter negation operation 443 | for index_negation in range(len(input_stl) - 1, -1, -1): 444 | if input_stl[index_negation] == 'negation' and input_stl[index_negation + 1][:5] == 'enter': 445 | phi = 'not_' + input_stl[index_negation + 1] 446 | input_stl.pop(index_negation + 1) 447 | input_stl.pop(index_negation) 448 | input_stl.insert(index_negation, phi) 449 | elif input_stl[index_negation] == 'negation' and input_stl[index_negation + 1][:9] == 'not_enter': 450 | phi = input_stl[index_negation + 1][4:] 451 | input_stl.pop(index_negation + 1) 452 | input_stl.pop(index_negation) 453 | input_stl.insert(index_negation, phi) 454 | 455 | if 'negation' in input_stl: 456 | for index_negation in range(len(input_stl) - 2): 457 | if input_stl[index_negation] == 'negation' and ( 458 | input_stl[index_negation + 1] == 'and' or input_stl[index_negation + 1] == 'or'): 459 | count_operator = 0 460 | for operator_index in range(index_negation, len(input_stl)): 461 | if input_stl[operator_index] == 'and': 462 | input_stl[operator_index] = 'or' 463 | count_operator += 1 464 | elif input_stl[operator_index] == 'or': 465 | input_stl[operator_index] = 'and' 466 | count_operator += 1 467 | elif input_stl[operator_index][:5] == 'enter': 468 | phi = 'not_' + input_stl[operator_index] 469 | input_stl[operator_index] = phi 470 | count_operator -= 1 471 | if count_operator == -1: 472 | break 473 | elif input_stl[operator_index][:9] == 'not_enter': 474 | phi = input_stl[operator_index][4:] 475 | input_stl[operator_index] = phi 476 | count_operator -= 1 477 | if count_operator == -1: 478 | break 479 | input_stl.pop(index_negation) 480 | return input_stl -------------------------------------------------------------------------------- /vis.py: -------------------------------------------------------------------------------- 1 | from gurobipy import * 2 | import numpy as np 3 | from collections import namedtuple 4 | import time 5 | import pickle 6 | import pypoman as ppm 7 | import matplotlib.pyplot as plt; plt.rcdefaults() 8 | import matplotlib.path as mpath 9 | import matplotlib.lines as mlines 10 | import matplotlib.patches as mpatches 11 | from matplotlib.collections import PatchCollection 12 | 13 | def vis(plots, PWLs, limits=None, equal_aspect=True): 14 | print(PWLs) 15 | plt.rcParams["figure.figsize"] = [6.4, 6.4] 16 | plt.rcParams['axes.titlesize'] = 20 17 | fig = plt.figure() 18 | ax = fig.add_subplot(111) 19 | ax.axis('off') 20 | 21 | vertices = [] 22 | for plot in plots: 23 | #print('plot: ', plot) 24 | for A, b in plot[0]: 25 | vs = ppm.duality.compute_polytope_vertices(A, b) 26 | vertices.append(vs) 27 | ppm.polygon.plot_polygon(vs, color = plot[1], alpha=1.) 28 | if plot[2] != 'wall': 29 | plt.text((-b[0] + b[1])/2-0.32, (-b[2] + b[3])/2-0.1, plot[2],color = (0.6,0.6,0.6), fontsize=12, fontweight='bold') 30 | 31 | if limits is not None: 32 | plt.xlim(limits[0]) 33 | plt.ylim(limits[1]) 34 | else: 35 | vertices = np.concatenate(vertices, axis=0) 36 | xmin, ymin = vertices.min(axis=0) 37 | xmax, ymax = vertices.max(axis=0) 38 | plt.xlim([xmin - 0.1, xmax + 0.1]) 39 | plt.ylim([ymin - 0.1, ymax + 0.1]) 40 | 41 | if equal_aspect: 42 | plt.gca().set_aspect('equal', adjustable='box') 43 | 44 | if PWLs is None or PWLs[0] is None: 45 | plt.show() 46 | return 47 | 48 | if len(PWLs) <= 4: 49 | colors = ['k', np.array([153,0,71])/255, np.array([6,0,153])/255, np.array([0, 150, 0])/255] 50 | else: 51 | cmap = plt.get_cmap('tab10') 52 | colors = [cmap(i) for i in np.linspace(0, 0.85, len(PWLs))] 53 | 54 | for i in range(len(PWLs)): 55 | PWL = PWLs[i] 56 | ax.plot([P[0][0] for P in PWL], [P[0][1] for P in PWL], '-', color = colors[i]) 57 | ax.plot(PWL[-1][0][0], PWL[-1][0][1], '*', color = colors[i]) 58 | ax.plot(PWL[0][0][0], PWL[0][0][1], 'o', color = colors[i]) 59 | plt.show() 60 | --------------------------------------------------------------------------------