Subagent: Two-handed longsword clips
agent (cont.)
+29:11Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14)" '{"x":[-0.10,-0.02],"y":[-0.36,-0.28],"z":[-0.36,-0.28,-0.20],"turn":[30,45],"lean":[10,18]}' 2>&1 | tail -8
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14)" '{"x":[-0.10,-0.02],"y":[-0.36,-0.28],"z":[-0.36,-0.28,-0.20],"turn":[30,45],"lean":[10,18]}' 2>&1 | tail -8result, 8 lines
{'x': -0.1, 'y': -0.28, 'z': -0.2, 'turn': 30, 'lean': 18} | clear -5.2 (R_UpperArm) off 0.1 miss 0.0 elb R 132 L 127 {'x': -0.1, 'y': -0.28, 'z': -0.2, 'turn': 45, 'lean': 18} | clear -5.7 (R_UpperArm) off 0.1 miss 0.0 elb R 134 L 110 {'x': -0.1, 'y': -0.28, 'z': -0.2, 'turn': 30, 'lean': 10} | clear -5.7 (R_UpperArm) off 0.1 miss 0.0 elb R 128 L 133 {'x': -0.1, 'y': -0.28, 'z': -0.2, 'turn': 45, 'lean': 10} | clear -6.3 (R_UpperArm) off 0.1 miss 0.0 elb R 131 L 118 {'x': -0.1, 'y': -0.28, 'z': -0.28, 'turn': 30, 'lean': 18} | clear -7.2 (R_UpperArm) off 0.1 miss 0.1 elb R 163 L 172 {'x': -0.02, 'y': -0.36, 'z': -0.2, 'turn': 30, 'lean': 10} | clear -7.3 (R_Hand) off 0.1 miss 0.0 elb R 143 L 157 {'x': -0.1, 'y': -0.28, 'z': -0.28, 'turn': 45, 'lean': 10} | clear -7.4 (R_UpperArm) off 0.1 miss 0.1 elb R 167 L 139 {'x': -0.02, 'y': -0.28, 'z': -0.36, 'turn': 45, 'lean': 10} | clear -7.0 (R_UpperArm) off 0.1 miss 0.5 elb R 178 L 177Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 viz.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),fist=(-0.10,-0.28,-0.20),turn=30,hip=14,lean=18)" shots/viz.png 2>&1 | tail -3
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 viz.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),fist=(-0.10,-0.28,-0.20),turn=30,hip=14,lean=18)" shots/viz.png 2>&1 | tail -3
result, 1 line
(Bash completed with no output)
Read~/Projects/lowmarch-fable52/review/out/whole-clips/shots/viz.png
input
{ "file_path": "~/Projects/lowmarch-fable52/review/out/whole-clips/shots/viz.png" }result
no output
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=18)" '{"x":[-0.14,-0.08],"y":[-0.30,-0.24],"z":[-0.26,-0.18],"turn":[30,45],"poleR":[(0.2,-0.4,-1),(1,-0.3,-0.3),(0.6,0.2,-1)]}' 2>&1 | tail -8
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=18)" '{"x":[-0.14,-0.08],"y":[-0.30,-0.24],"z":[-0.26,-0.18],"turn":[30,45],"poleR":[(0.2,-0.4,-1),(1,-0.3,-0.3),(0.6,0.2,-1)]}' 2>&1 | tail -8result, 8 lines
{'x': -0.08, 'y': -0.24, 'z': -0.26, 'turn': 45, 'poleR': (0.2, -0.4, -1)} | clear -3.8 (R_UpperArm) off 0.0 miss 0.1 elb R 125 L 127 {'x': -0.08, 'y': -0.24, 'z': -0.26, 'turn': 45, 'poleR': (1, -0.3, -0.3)} | clear -3.8 (R_UpperArm) off 0.0 miss 0.1 elb R 125 L 127 {'x': -0.08, 'y': -0.24, 'z': -0.26, 'turn': 45, 'poleR': (0.6, 0.2, -1)} | clear -3.8 (R_UpperArm) off 0.0 miss 0.1 elb R 125 L 127 {'x': -0.08, 'y': -0.24, 'z': -0.18, 'turn': 45, 'poleR': (0.2, -0.4, -1)} | clear -3.9 (R_UpperArm) off 0.1 miss 0.0 elb R 110 L 107 {'x': -0.08, 'y': -0.24, 'z': -0.18, 'turn': 45, 'poleR': (1, -0.3, -0.3)} | clear -4.0 (R_UpperArm) off 0.1 miss 0.1 elb R 108 L 107 {'x': -0.08, 'y': -0.24, 'z': -0.18, 'turn': 45, 'poleR': (0.6, 0.2, -1)} | clear -4.0 (R_UpperArm) off 0.1 miss 0.1 elb R 108 L 107 {'x': -0.08, 'y': -0.3, 'z': -0.18, 'turn': 45, 'poleR': (0.6, 0.2, -1)} | clear -4.3 (R_UpperArm) off 0.1 miss 0.0 elb R 132 L 107 {'x': -0.08, 'y': -0.3, 'z': -0.18, 'turn': 45, 'poleR': (0.2, -0.4, -1)} | clear -4.3 (R_UpperArm) off 0.1 miss 0.0 elb R 133 L 107Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail import sys, h, numpy as np v,shape=h.load(); sys.path.insert(0,h.ROOT+'/tools/whole') import clips2h f=clips2h.Fighter(v,shape) k=dict(clips2h.hermite(clips2h.ATTACK,0.68), blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=18,fist=(-0.08,-0.24,-0.22),turn=45) for share in (0.0,0.15,0.3,0.5): g=clips2h.Fighter.girdle f.girdle=lambda pose,side,target,share=share,cap=30: g(f,pose,side,target,share,cap) for pole in [(0.4,-1,-0.3),(1,0,0),(0.3,0.3,-1),(1,-1,0.5)]: p=f.solve(dict(k,poleR=pole)) # direct grip without clear print(share,pole,{n:round(c*100,1) for n,c in f.body.clearance(p).items() if n.startswith('R')}) EOFresult, 10 lines
0.15 (0.3, 0.3, -1) {'R_UpperArm': -4.0, 'R_LowerArm': 0.5, 'R_Hand': 4.9} 0.15 (1, -1, 0.5) {'R_UpperArm': -4.0, 'R_LowerArm': 0.5, 'R_Hand': 4.9} 0.3 (0.4, -1, -0.3) {'R_UpperArm': -3.9, 'R_LowerArm': 2.1, 'R_Hand': 5.5} 0.3 (1, 0, 0) {'R_UpperArm': -3.9, 'R_LowerArm': 2.1, 'R_Hand': 5.5} 0.3 (0.3, 0.3, -1) {'R_UpperArm': -3.9, 'R_LowerArm': 2.1, 'R_Hand': 5.5} 0.3 (1, -1, 0.5) {'R_UpperArm': -3.9, 'R_LowerArm': 2.1, 'R_Hand': 5.5} 0.5 (0.4, -1, -0.3) {'R_UpperArm': -3.9, 'R_LowerArm': 2.2, 'R_Hand': 5.6} 0.5 (1, 0, 0) {'R_UpperArm': -3.9, 'R_LowerArm': 2.2, 'R_Hand': 5.6} 0.5 (0.3, 0.3, -1) {'R_UpperArm': -3.9, 'R_LowerArm': 8.4, 'R_Hand': 4.5} 0.5 (1, -1, 0.5) {'R_UpperArm': -3.9, 'R_LowerArm': 2.2, 'R_Hand': 5.6}Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail -20
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail -20 import sys, h, numpy as np v,shape=h.load(); sys.path.insert(0,h.ROOT+'/tools/whole') import clips2h f=clips2h.Fighter(v,shape); r=f.rig k=dict(clips2h.hermite(clips2h.ATTACK,0.68), blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=18,fist=(-0.08,-0.24,-0.22),turn=45) cg=clips2h.clear_grip store={} def spy(rig, body, pose, side, ref, fist, D, poles, need=0.012): store[side]=(pose,fist,D) return cg(rig, body, pose, side, ref, fist, D, poles, need) clips2h.clear_grip=spy p=f.solve(k) pose,fist,D=store['R'] for pole in [(0.4,-1,-0.3),(1,0,0),(0.3,0.3,-1),(1,-1,0.5),(0,-1,0),(-0.5,-0.5,-1),(1,1,0)]: q=clips2h.grip(r,pose,'R',f.ref,fist,D,pole) c=f.body.clearance(q) print(pole,'E-S',(r.pos(q,'J_Bip_R_LowerArm')-r.pos(q,'J_Bip_R_UpperArm')).round(2),{n:round(x*100,1) for n,x in c.items() if n.startswith('R')}) print('S',r.pos(pose,'J_Bip_R_UpperArm').round(3),'fist',fist.round(3)) EOFresult, 8 lines
(0.4, -1, -0.3) E-S [-0.08 -0.24 0.01] {'R_UpperArm': -3.8, 'R_LowerArm': 1.3, 'R_Hand': 5.4} (1, 0, 0) E-S [-0.06 -0.23 0.09] {'R_UpperArm': -8.3, 'R_LowerArm': -6.2, 'R_Hand': 5.4} (0.3, 0.3, -1) E-S [-0.18 -0.16 -0.07] {'R_UpperArm': -4.8, 'R_LowerArm': 6.4, 'R_Hand': 4.4} (1, -1, 0.5) E-S [-0.06 -0.22 0.1 ] {'R_UpperArm': -8.8, 'R_LowerArm': -7.0, 'R_Hand': 5.6} (0, -1, 0) E-S [-0.07 -0.24 0.03] {'R_UpperArm': -4.9, 'R_LowerArm': -0.0, 'R_Hand': 5.3} (-0.5, -0.5, -1) E-S [-0.17 -0.16 -0.07] {'R_UpperArm': -4.8, 'R_LowerArm': 6.5, 'R_Hand': 4.2} (1, 1, 0) E-S [-0.15 -0.11 0.16] {'R_UpperArm': -12.1, 'R_LowerArm': -7.6, 'R_Hand': 4.3} S [ 0.05 1.149 -0.4 ] fist [-0.211 0.841 -0.312]Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=14)" '{"x":[-0.10,-0.04,0.02],"y":[-0.30,-0.22,-0.14],"z":[-0.44,-0.36],"turn":[25,40]}' 2>&1 | tail -8
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 grid.py 0.68 "dict(blade=(-0.55,-0.45,0.70),poleL=(-1,-0.4,0.4),hip=14,lean=14)" '{"x":[-0.10,-0.04,0.02],"y":[-0.30,-0.22,-0.14],"z":[-0.44,-0.36],"turn":[25,40]}' 2>&1 | tail -8result, 8 lines
{'x': -0.1, 'y': -0.22, 'z': -0.36, 'turn': 40} | clear -6.4 (R_UpperArm) off 0.3 miss 0.6 elb R 178 L 142 {'x': 0.02, 'y': -0.14, 'z': -0.36, 'turn': 40} | clear -3.8 (L_UpperArm) off 2.5 miss 0.1 elb R 101 L 178 {'x': 0.02, 'y': -0.14, 'z': -0.44, 'turn': 25} | clear -3.2 (L_UpperArm) off 2.9 miss 0.0 elb R 129 L 178 {'x': 0.02, 'y': -0.3, 'z': -0.36, 'turn': 40} | clear -7.7 (L_UpperArm) off 0.7 miss 0.5 elb R 178 L 178 {'x': 0.02, 'y': -0.14, 'z': -0.36, 'turn': 25} | clear -3.2 (L_UpperArm) off 3.8 miss 0.0 elb R 99 L 178 {'x': -0.04, 'y': -0.22, 'z': -0.36, 'turn': 40} | clear -6.1 (L_UpperArm) off 2.9 miss 0.1 elb R 136 L 178 {'x': 0.02, 'y': -0.3, 'z': -0.36, 'turn': 25} | clear -8.0 (L_UpperArm) off 2.0 miss 0.1 elb R 164 L 178 {'x': -0.04, 'y': -0.14, 'z': -0.44, 'turn': 40} | clear -3.9 (R_UpperArm) off 4.3 miss 0.0 elb R 150 L 178Write~/Projects/lowmarch-fable52/review/out/whole-clips/rnd.py
input
~/Projects/lowmarch-fable52/review/out/whole-clips/rnd.py """Random search one key: python3 rnd.py T 'base' 'ranges' N -> the clearest keys that hit the grip. ranges: {name: (lo, hi)} for scalars, or {"x"/"y"/"z": (lo, hi)} for the fist, {"bx","by","bz"} for the blade.""" import sys import numpy as np ARGV = list(sys.argv) import h v, shape = h.load() sys.path.insert(0, f"{h.ROOT}/tools/whole") import clips2h import poses as P f = clips2h.Fighter(v, shape) rig = f.rig t = float(ARGV[1]) base = dict(clips2h.hermite(clips2h.ATTACK, t) if t > 0 else clips2h.guard_at(0.0), **eval(ARGV[2])) rng_ = eval(ARGV[3]) N = int(ARGV[4]) R = np.random.default_rng(1) res = [] for _ in range(N): c = {n: float(R.uniform(*r)) if not isinstance(r[0], tuple) else r[R.integers(len(r))] for n, r in rng_.items()} k = dict(base) fx, bl = list(base["fist"]), list(base["blade"]) for i, n in enumerate("xyz"): if n in c: fx[i] = c[n] if "b" + n in c: bl[i] = c["b" + n] k.update({n: x for n, x in c.items() if n not in ("x", "y", "z", "bx", "by", "bz")}, fist=tuple(fx), blade=tuple(bl)) pose = f.solve(k) cl = f.body.clearance(pose) a, d = f.sword(pose) lf = rig.held(pose, "J_Bip_L_Hand", P.BUST, f.ref["fist_L"]) off = np.linalg.norm((lf - a) - d * ((lf - a) @ d)) Wc = rig.world(pose)[rig.names["J_Bip_C_UpperChest"]] tgt = Wc[:3, 3] + f._rot(Wc) @ f.chest0.T @ np.array(fx) miss = np.linalg.norm(a - tgt) elb = [] for s in "RL": S, E, W = (rig.pos(pose, f"J_Bip_{s}_{b}") for b in ("UpperArm", "LowerArm", "Hand")) u1, u2 = S - E, W - E elb.append(np.degrees(np.arccos(u1 @ u2 / np.linalg.norm(u1) / np.linalg.norm(u2)))) score = min(min(cl.values()), 0.03) - 2 * max(off - 0.003, 0) - 2 * max(miss - 0.003, 0) - 0.001 * max(max(elb) - 160, 0) res.append((score, c, min(cl.values()), off, miss, elb, min(cl, key=cl.get), a.round(2))) res.sort(key=lambda r: -r[0]) for r in res[:12]: print("{" + ", ".join(f"'{n}': {x:.3f}" if isinstance(x, float) else f"'{n}': {x}" for n, x in r[1].items()) + "}" + f" | clear {r[2] * 100:5.1f} ({r[6]}) off {r[3] * 100:4.1f} miss {r[4] * 100:4.1f} elb R{r[5][0]:4.0f} L{r[5][1]:4.0f} fist {r[7]}")result, 1 line
File created successfully at: ~/Projects/lowmarch-fable52/review/out/whole-clips/rnd.py (file state is current in your context — no need to Read it back)
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && time OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.68 "dict(poleL=(-1,-0.4,0.4),hip=14)" '{"x":(-0.25,0.05),"y":(-0.45,-0.12),"z":(-0.45,-0.1),"turn":(15,50),"lean":(8,28),"bx":(-0.7,-0.2),"by":(-0.9,-0.3),"bz":(-0.3,0.8)}' 200 2>&1 | tail -12
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && time OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.68 "dict(poleL=(-1,-0.4,0.4),hip=14)" '{"x":(-0.25,0.05),"y":(-0.45,-0.12),"z":(-0.45,-0.1),"turn":(15,50),"lean":(8,28),"bx":(-0.7,-0.2),"by":(-0.9,-0.3),"bz":(-0.3,0.8)}' 200 2>&1 | tail -12result, 16 lines
{'x': -0.013, 'y': -0.120, 'z': -0.284, 'turn': 25.381, 'lean': 19.590, 'bx': -0.514, 'by': -0.830, 'bz': 0.277} | clear 0.1 (R_UpperArm) off 0.1 miss 0.0 elb R 86 L 101 fist [-0.15 0.91 -0.49] {'x': 0.038, 'y': -0.211, 'z': -0.261, 'turn': 24.691, 'lean': 11.213, 'bx': -0.215, 'by': -0.590, 'bz': -0.173} | clear 0.0 (L_UpperArm) off 0.0 miss 0.0 elb R 107 L 85 fist [-0.08 0.87 -0.47] {'x': -0.058, 'y': -0.177, 'z': -0.225, 'turn': 38.339, 'lean': 25.081, 'bx': -0.663, 'by': -0.589, 'bz': -0.271} | clear -0.1 (R_UpperArm) off 0.0 miss 0.0 elb R 93 L 62 fist [-0.19 0.87 -0.37] {'x': -0.003, 'y': -0.225, 'z': -0.218, 'turn': 38.850, 'lean': 14.991, 'bx': -0.210, 'by': -0.698, 'bz': -0.094} | clear -0.9 (R_UpperArm) off 0.1 miss 0.0 elb R 108 L 67 fist [-0.14 0.86 -0.38] {'x': -0.058, 'y': -0.169, 'z': -0.242, 'turn': 24.103, 'lean': 24.798, 'bx': -0.445, 'by': -0.593, 'bz': 0.528} | clear -1.5 (R_UpperArm) off 0.1 miss 0.1 elb R 93 L 95 fist [-0.16 0.86 -0.43] {'x': -0.028, 'y': -0.235, 'z': -0.238, 'turn': 16.192, 'lean': 16.589, 'bx': -0.357, 'by': -0.806, 'bz': 0.124} | clear -1.7 (R_UpperArm) off 0.1 miss 0.0 elb R 116 L 103 fist [-0.1 0.83 -0.43] {'x': -0.038, 'y': -0.158, 'z': -0.185, 'turn': 47.270, 'lean': 16.296, 'bx': -0.683, 'by': -0.791, 'bz': 0.017} | clear -1.7 (L_LowerArm) off 0.1 miss 0.0 elb R 86 L 73 fist [-0.17 0.93 -0.33] {'x': -0.046, 'y': -0.145, 'z': -0.173, 'turn': 15.751, 'lean': 8.779, 'bx': -0.444, 'by': -0.556, 'bz': 0.367} | clear -1.7 (R_LowerArm) off 0.0 miss 0.0 elb R 72 L 80 fist [-0.1 0.96 -0.38] {'x': -0.063, 'y': -0.194, 'z': -0.235, 'turn': 47.105, 'lean': 8.792, 'bx': -0.436, 'by': -0.624, 'bz': -0.231} | clear -1.8 (R_UpperArm) off 0.1 miss 0.0 elb R 104 L 62 fist [-0.22 0.91 -0.33] {'x': -0.027, 'y': -0.227, 'z': -0.294, 'turn': 37.666, 'lean': 26.883, 'bx': -0.279, 'by': -0.559, 'bz': 0.699} | clear -1.8 (R_UpperArm) off 0.0 miss 0.1 elb R 115 L 132 fist [-0.2 0.78 -0.42] {'x': 0.028, 'y': -0.183, 'z': -0.299, 'turn': 41.822, 'lean': 12.677, 'bx': -0.248, 'by': -0.732, 'bz': 0.778} | clear -2.0 (L_UpperArm) off 0.1 miss 0.0 elb R 92 L 140 fist [-0.18 0.89 -0.46] {'x': -0.112, 'y': -0.223, 'z': -0.148, 'turn': 28.675, 'lean': 22.236, 'bx': -0.323, 'by': -0.853, 'bz': -0.148} | clear -2.0 (R_UpperArm) off 0.0 miss 0.0 elb R 101 L 55 fist [-0.17 0.86 -0.3 ] real 3m10.605s user 1m28.825s sys 0m4.783sBashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail -20
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 - <<'EOF' 2>&1 | tail -20 import sys, h, numpy as np v,shape=h.load(); sys.path.insert(0,h.ROOT+'/tools/whole') import clips2h f=clips2h.Fighter(v,shape); r=f.rig def conv(k): p=f.solve(k) Wc=r.world(p)[r.names["J_Bip_C_UpperChest"]] return (f.chest0 @ f._rot(Wc).T @ np.asarray(k['fist'])).round(3) print('GUARD', conv(clips2h.GUARD)) print('BREATH', conv(dict(clips2h.GUARD, **clips2h.BREATH))) for t,k,hd in clips2h.ATTACK[1:-1]: print(t, conv(k)) EOFresult, 12 lines
GUARD [-0.027 -0.166 -0.342] BREATH [-0.025 -0.163 -0.345] 0.2 [ 0.02 -0.028 -0.234] 0.32 [ 0.121 0.08 -0.17 ] 0.44 [ 0.142 0.098 -0.157] 0.5 [ 0.067 0.141 -0.307] 0.56 [ 0.179 0.093 -0.436] 0.62 [ 0.224 -0.076 -0.499] 0.68 [ 0.217 -0.229 -0.47 ] 0.9 [ 0.191 -0.217 -0.462] 1.05 [ 0.191 -0.217 -0.462] 1.25 [ 0.058 -0.195 -0.432]
Bashcd ~/Projects/lowmarch-fable52/tools/whole && sed -n 28,75p clips2h.py
command
cd ~/Projects/lowmarch-fable52/tools/whole && sed -n 28,75p clips2h.py
result, 47 lines
# A key: hips down (drop) and forward (fwd), the hips' and the shoulders' turn (degrees, + brings the right # side forward), forward lean, the lead (left) foot's step and lift, the right fist from the upper chest in # model space (+x her right, -z forward), the blade's direction, each elbow's preferred direction, and how # far down the gaze tips. GUARD = dict(drop=0.06, fwd=0.0, hip=-22.0, turn=-14.0, lean=6.0, lead=0.0, lift=0.0, fist=(0.05, -0.20, -0.32), blade=(-0.05, 0.45, -0.89), poleR=(1.0, -0.7, 0.25), poleL=(-0.8, -1.0, 0.2), gaze=-0.06) BREATH = dict(drop=0.075, lean=8.5, fist=(0.05, -0.212, -0.315), blade=(-0.05, 0.40, -0.91)) # the low end IDLE_LOOP, IDLE_STEP, BLADE_LAG = 2.0, 0.2, 0.1 # elbow directions tried after a key's own when its arm meets the body (right arm; mirrored for the left) POLES = [(1.0, -0.5, 0.0), (0.6, -1.0, -0.4), (1.0, -0.2, 0.4)] def key(**kw): return dict(GUARD, **kw) # (time, key, hold): a held key eases in and out (no velocity through it) ATTACK = [ (0.0, key(), True), (0.2, key(drop=0.065, fwd=-0.02, hip=-26.0, turn=-26.0, lean=3.0, fist=(0.12, -0.04, -0.20), blade=(0.12, 0.98, -0.12)), False), (0.32, key(drop=0.07, fwd=-0.05, hip=-30.0, turn=-38.0, lean=0.0, fist=(0.20, 0.08, -0.06), blade=(0.30, 0.70, 0.65), poleR=(1.0, -0.6, 0.2)), False), (0.44, key(drop=0.08, fwd=-0.06, hip=-32.0, turn=-42.0, lean=-1.0, fist=(0.21, 0.10, -0.02), blade=(0.32, 0.55, 0.77), poleR=(1.0, -0.6, 0.2)), True), (0.5, key(drop=0.08, fwd=0.06, hip=-4.0, turn=-10.0, lean=4.0, lead=0.15, lift=0.06, fist=(0.12, 0.12, -0.30), blade=(0.15, 0.90, -0.40)), False), (0.56, key(drop=0.11, fwd=0.16, hip=10.0, turn=22.0, lean=14.0, lead=0.30, fist=(0.0, -0.02, -0.48), blade=(-0.30, -0.10, -0.95)), False), (0.62, key(drop=0.12, fwd=0.17, hip=15.0, turn=34.0, lean=16.0, lead=0.30, fist=(-0.08, -0.22, -0.50), blade=(-0.50, -0.55, -0.60)), False), (0.68, key(drop=0.12, fwd=0.17, hip=18.0, turn=42.0, lean=16.0, lead=0.30, fist=(-0.12, -0.36, -0.42), blade=(-0.60, -0.70, 0.30), poleR=(0.4, -1.0, -0.3)), False), (0.9, key(drop=0.11, fwd=0.16, hip=16.0, turn=38.0, lean=14.0, lead=0.30, fist=(-0.11, -0.33, -0.42), blade=(-0.60, -0.62, 0.36), poleR=(0.4, -1.0, -0.3)), True), (1.05, key(drop=0.11, fwd=0.16, hip=16.0, turn=38.0, lean=14.0, lead=0.30, fist=(-0.11, -0.33, -0.42), blade=(-0.60, -0.62, 0.36), poleR=(0.4, -1.0, -0.3)), True), (1.25, key(drop=0.08, fwd=0.06, hip=-8.0, turn=10.0, lean=9.0, lead=0.14, lift=0.04, fist=(-0.02, -0.26, -0.40), blade=(-0.45, 0.10, -0.85)), False), (1.5, key(), True), ] SAMPLES = [0.0, 0.1, 0.2, 0.26, 0.32, 0.38, 0.44, 0.47, 0.5, 0.53, 0.56, 0.59, 0.62, 0.65, 0.68, 0.78, 0.9, 1.05, 1.15, 1.25, 1.35, 1.42, 1.5] def hermite(keys, t):Bashcd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF'
command
cd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF' s=open('clips2h.py').read() i=s.index('# A key: hips down'); j=s.index('SAMPLES = [') new='''# A key: hips down (drop) and forward (fwd), the hips' and the shoulders' turn (degrees, + brings the right # side forward), forward lean, the lead (left) foot's step and lift, the right fist from the upper chest in the # chest's own frame (+x her right, -z forward, turned and leaned with her), the blade's direction in model # space, each elbow's preferred direction, and how far down the gaze tips. GUARD = dict(drop=0.06, fwd=0.0, hip=-22.0, turn=-14.0, lean=6.0, lead=0.0, lift=0.0, fist=(-0.027, -0.166, -0.342), blade=(-0.05, 0.55, -0.83), poleR=(1.0, -0.7, 0.25), poleL=(-0.8, -1.0, 0.2), gaze=-0.06) BREATH = dict(drop=0.075, lean=8.5, fist=(-0.027, -0.176, -0.338), blade=(-0.05, 0.50, -0.86)) # the low end IDLE_LOOP, IDLE_STEP, BLADE_LAG = 2.0, 0.2, 0.1 # elbow directions tried after a key's own when its arm meets the body (right arm; mirrored for the left) POLES = [(1.0, -0.5, 0.0), (0.6, -1.0, -0.4), (1.0, -0.2, 0.4)] def key(**kw): return dict(GUARD, **kw) # (time, key, hold): a held key eases in and out (no velocity through it) ATTACK = [ (0.0, key(), True), (0.2, key(drop=0.065, fwd=-0.02, hip=-26.0, turn=-26.0, lean=3.0, fist=(0.02, -0.03, -0.24), blade=(0.12, 0.98, -0.12)), False), (0.32, key(drop=0.07, fwd=-0.05, hip=-30.0, turn=-38.0, lean=0.0, fist=(0.042, 0.08, -0.25), blade=(0.30, 0.70, 0.65), poleR=(1.0, -0.6, 0.2), poleL=(-0.2, -0.8, -1.0)), False), (0.44, key(drop=0.08, fwd=-0.06, hip=-32.0, turn=-42.0, lean=-1.0, fist=(0.07, 0.10, -0.23), blade=(0.32, 0.55, 0.77), poleR=(1.0, -0.6, 0.2), poleL=(-0.2, -0.8, -1.0)), True), (0.5, key(drop=0.08, fwd=0.06, hip=-4.0, turn=-10.0, lean=4.0, lead=0.15, lift=0.06, fist=(0.067, 0.141, -0.307), blade=(0.15, 0.90, -0.40)), False), (0.56, key(drop=0.11, fwd=0.16, hip=10.0, turn=22.0, lean=14.0, lead=0.30, fist=(0.15, 0.05, -0.42), blade=(-0.30, -0.40, -0.87)), False), (0.62, key(drop=0.12, fwd=0.17, hip=13.0, turn=24.0, lean=17.0, lead=0.30, fist=(0.07, -0.05, -0.36), blade=(-0.45, -0.70, -0.50)), False), (0.68, key(drop=0.12, fwd=0.17, hip=14.0, turn=25.0, lean=19.6, lead=0.30, fist=(-0.013, -0.12, -0.284), blade=(-0.51, -0.83, 0.28), poleL=(-1.0, -0.4, 0.4)), False), (0.9, key(drop=0.11, fwd=0.16, hip=13.0, turn=24.0, lean=18.0, lead=0.30, fist=(-0.01, -0.11, -0.28), blade=(-0.50, -0.80, 0.30), poleL=(-1.0, -0.4, 0.4)), True), (1.05, key(drop=0.11, fwd=0.16, hip=13.0, turn=24.0, lean=18.0, lead=0.30, fist=(-0.01, -0.11, -0.28), blade=(-0.50, -0.80, 0.30), poleL=(-1.0, -0.4, 0.4)), True), (1.25, key(drop=0.08, fwd=0.06, hip=-8.0, turn=6.0, lean=10.0, lead=0.14, lift=0.04, fist=(0.03, -0.17, -0.36), blade=(-0.45, 0.10, -0.85)), False), (1.5, key(), True), ] ''' s=s[:i]+new+s[j:] open('clips2h.py','w').write(s) EOF cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 t.py 2>&1 | grep -v "^ [~!]" | cut -c1-250result, 37 lines
solve 19.1s (setup 0.5s) wren: 34 keyframes checked; 3 with an arm through the body, 22 with an arm resting on it idle 0.00 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 idle 0.20 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 idle 0.40 span 9.5 off 0.2 | hd 44.7 38.2 26.7 paul 29.9 legs 38.4 tip 1.44 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-12 | RUpp-0.1 LUpp 2.2 idle 0.60 span 9.5 off 0.2 | hd 44.4 38.7 27.2 paul 29.8 legs 39.2 tip 1.48 | elb R 109 L 96 reach R0.42 L0.40 | hipext R-11 | RUpp-0.1 LUpp 2.3 idle 0.80 span 9.5 off 0.2 | hd 44.2 39.1 27.5 paul 29.7 legs 39.7 tip 1.51 | elb R 109 L 96 reach R0.42 L0.40 | hipext R -9 | RUpp 0.1 LUpp 2.3 idle 1.00 span 9.5 off 0.2 | hd 44.1 39.2 27.5 paul 29.7 legs 39.7 tip 1.51 | elb R 109 L 96 reach R0.42 L0.40 | hipext R -9 | RUpp 0.1 LUpp 2.3 idle 1.20 span 9.5 off 0.2 | hd 44.1 39.1 27.5 paul 29.7 legs 39.6 tip 1.51 | elb R 109 L 96 reach R0.42 L0.40 | hipext R -9 | RUpp 0.1 LUpp 2.3 idle 1.40 span 9.5 off 0.2 | hd 44.4 38.6 26.7 paul 30.0 legs 38.5 tip 1.47 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-12 | RUpp-0.1 LUpp 2.2 idle 1.60 span 9.5 off 0.2 | hd 44.8 38.1 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 idle 1.80 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 idle 2.00 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 attack 0.00 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 attack 0.10 span 9.5 off 0.1 | hd 34.6 34.9 22.9 paul 24.1 legs 40.3 tip 1.75 | elb R 86 L 87 reach R0.36 L0.37 | hipext R-13 | RUpp 1.6 LUpp 2.0 attack 0.20 span 9.5 off 0.0 | hd 16.1 20.2 21.4 paul 15.7 legs 47.4 tip 2.08 | elb R 59 L 67 reach R0.26 L0.31 | hipext R-12 | LUpp 1.9 attack 0.26 span 9.5 off 0.0 | hd 13.1 15.8 21.6 paul 14.6 legs 50.3 tip 2.09 | elb R 57 L 58 reach R0.24 L0.29 | hipext R-14 | LUpp 1.9 attack 0.32 span 9.5 off 0.1 | hd 14.4 15.6 21.7 paul 15.4 legs 52.0 tip 1.92 | elb R 61 L 54 reach R0.24 L0.28 | hipext R-16 | attack 0.38 span 9.5 off 0.0 | hd 14.4 14.6 20.9 paul 15.3 legs 52.2 tip 1.83 | elb R 59 L 52 reach R0.22 L0.28 | hipext R-18 | LUpp 2.5 attack 0.44 span 9.5 off 0.0 | hd 13.9 14.0 20.2 paul 14.5 legs 51.9 tip 1.80 | elb R 56 L 50 reach R0.21 L0.27 | hipext R-18 | LUpp 1.7 attack 0.47 span 9.5 off 0.1 | hd 16.2 16.2 24.5 paul 18.1 legs 58.9 tip 2.14 | elb R 57 L 58 reach R0.24 L0.29 | hipext R-11 | LUpp 1.0 attack 0.50 span 9.5 off 0.1 | hd 23.8 20.6 31.4 paul 19.2 legs 65.3 tip 2.15 | elb R 64 L 70 reach R0.29 L0.31 | hipext R 6 | LUpp 2.4 attack 0.53 span 9.5 off 0.1 | hd 38.1 25.2 30.2 paul 21.7 legs 62.4 tip 1.55 | elb R 87 L 87 reach R0.34 L0.36 | hipext R 15 | LUpp 1.5 attack 0.56 span 9.5 off 0.0 | hd 48.7 27.0 28.1 paul 25.6 legs 55.7 tip 0.70 | elb R 113 L 104 reach R0.39 L0.41 | hipext R 22 | LUpp 1.8 attack 0.59 span 9.5 off 0.0 | hd 49.0 26.9 25.3 paul 24.9 legs 46.8 tip 0.46 | elb R 108 L 94 reach R0.38 L0.39 | hipext R 23 | RUpp 2.2 LUpp 1.4 attack 0.62 span 9.5 off 0.1 | hd 47.8 26.0 22.9 paul 22.1 legs 35.5 tip 0.29 | elb R 99 L 95 reach R0.36 L0.35 | hipext R 22 | RUpp 0.3 LUpp-1.7 attack 0.65 span 9.5 off 0.0 | hd 38.2 26.7 24.4 paul 19.9 legs 18.8 tip 0.13 | elb R 90 L 110 reach R0.35 L0.32 | hipext R 21 | RUpp 0.1 LUpp-1.0 attack 0.68 span 9.5 off 0.1 | hd 31.4 25.2 22.7 paul 20.5 legs 12.1 tip 0.14 | elb R 86 L 101 reach R0.35 L0.31 | hipext R 21 | RUpp-0.1 LUpp 0.7 attack 0.78 span 9.5 off 0.1 | hd 29.7 24.6 22.7 paul 20.3 legs 11.5 tip 0.17 | elb R 84 L 97 reach R0.35 L0.31 | hipext R 20 | RUpp 0.1 LUpp 1.2 attack 0.90 span 9.5 off 0.1 | hd 31.2 26.3 23.9 paul 20.7 legs 12.9 tip 0.18 | elb R 82 L 99 reach R0.34 L0.31 | hipext R 20 | RUpp 0.5 LUpp 1.1 attack 1.05 span 9.5 off 0.1 | hd 31.2 26.3 23.9 paul 20.7 legs 12.9 tip 0.18 | elb R 82 L 99 reach R0.34 L0.31 | hipext R 20 | RUpp 0.5 LUpp 1.1 attack 1.15 span 9.5 off 0.1 | hd 42.6 31.6 18.0 paul 24.1 legs 24.2 tip 0.36 | elb R 100 L 94 reach R0.37 L0.34 | hipext R 11 | RUpp-1.2 LUpp-1.2 attack 1.25 span 9.5 off 0.2 | hd 49.8 36.8 22.7 paul 31.9 legs 34.2 tip 1.04 | elb R 110 L 101 reach R0.42 L0.41 | hipext R -0 | RUpp 0.7 LUpp 0.8 attack 1.35 span 9.5 off 0.2 | hd 48.0 37.9 26.2 paul 32.4 legs 36.8 tip 1.26 | elb R 112 L 103 reach R0.43 L0.42 | hipext R -8 | RUpp 0.6 LUpp 1.4 attack 1.42 span 9.5 off 0.2 | hd 46.0 37.9 26.8 paul 30.9 legs 37.6 tip 1.37 | elb R 111 L 100 reach R0.43 L0.41 | hipext R-12 | RUpp 0.1 LUpp 2.0 attack 1.50 span 9.5 off 0.2 | hd 44.8 38.0 26.3 paul 30.0 legs 37.8 tip 1.43 | elb R 110 L 97 reach R0.42 L0.40 | hipext R-14 | RUpp-0.1 LUpp 2.2 total 27s
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.62 "{}" '{"x":(0.0,0.12),"y":(-0.10,0.0),"z":(-0.42,-0.30),"turn":(18,30),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3))}' 40 2>&1 | tail -5; OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 1.15 "{}" '{"x":(-0.04,0.08),"y":(-0.18,-0.08),"z":(-0.40,-0.26),"turn":(10,24),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3)),"poleR":((1,-0.7,0.25),(0.4,-1,-0.3),(1,-0.2,-0.5))}' 40 2>&1 | tail -5
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.62 "{}" '{"x":(0.0,0.12),"y":(-0.10,0.0),"z":(-0.42,-0.30),"turn":(18,30),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3))}' 40 2>&1 | tail -5; OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 1.15 "{}" '{"x":(-0.04,0.08),"y":(-0.18,-0.08),"z":(-0.40,-0.26),"turn":(10,24),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3)),"poleR":((1,-0.7,0.25),(0.4,-1,-0.3),(1,-0.2,-0.5))}' 40 2>&1 | tail -5result, 10 lines
{'x': 0.097, 'y': -0.004, 'z': -0.402, 'turn': 23.787, 'poleL': (-0.8, -1, 0.2)} | clear -0.5 (L_UpperArm) off 0.0 miss 0.1 elb R 105 L 102 fist [-0.09 1. -0.67] {'x': 0.043, 'y': -0.036, 'z': -0.374, 'turn': 22.578, 'poleL': (-1, -0.6, -0.3)} | clear -0.5 (L_UpperArm) off 0.0 miss 0.1 elb R 105 L 99 fist [-0.12 0.98 -0.62] {'x': 0.051, 'y': -0.017, 'z': -0.371, 'turn': 24.595, 'poleL': (-1, -0.4, 0.4)} | clear -0.5 (L_UpperArm) off 0.1 miss 0.1 elb R 100 L 108 fist [-0.13 1. -0.62] {'x': 0.057, 'y': -0.073, 'z': -0.419, 'turn': 25.749, 'poleL': (-1, -0.6, -0.3)} | clear -0.6 (R_UpperArm) off 0.0 miss 0.1 elb R 130 L 94 fist [-0.14 0.93 -0.65] {'x': 0.086, 'y': -0.016, 'z': -0.386, 'turn': 20.583, 'poleL': (-1, -0.6, -0.3)} | clear -0.7 (L_UpperArm) off 0.1 miss 0.1 elb R 100 L 103 fist [-0.07 0.99 -0.66] {'x': 0.020, 'y': -0.178, 'z': -0.331, 'turn': 23.602, 'poleL': (-1, -0.6, -0.3), 'poleR': (1, -0.7, 0.25)} | clear -1.5 (R_UpperArm) off 0.0 miss 0.1 elb R 114 L 93 fist [-0.11 0.89 -0.48] {'x': 0.038, 'y': -0.137, 'z': -0.279, 'turn': 18.850, 'poleL': (-1, -0.4, 0.4), 'poleR': (1, -0.2, -0.5)} | clear -1.6 (L_UpperArm) off 0.0 miss 0.1 elb R 87 L 92 fist [-0.06 0.94 -0.46] {'x': -0.037, 'y': -0.113, 'z': -0.271, 'turn': 21.576, 'poleL': (-0.8, -1, 0.2), 'poleR': (1, -0.2, -0.5)} | clear -1.6 (R_UpperArm) off 0.0 miss 0.1 elb R 95 L 76 fist [-0.14 0.97 -0.43] {'x': 0.014, 'y': -0.167, 'z': -0.344, 'turn': 12.848, 'poleL': (-0.8, -1, 0.2), 'poleR': (1, -0.7, 0.25)} | clear -1.7 (R_UpperArm) off 0.0 miss 0.0 elb R 114 L 101 fist [-0.06 0.9 -0.51] {'x': 0.021, 'y': -0.085, 'z': -0.380, 'turn': 23.281, 'poleL': (-1, -0.4, 0.4), 'poleR': (1, -0.7, 0.25)} | clear -1.7 (L_UpperArm) off 0.0 miss 0.1 elb R 112 L 98 fist [-0.13 0.97 -0.55]Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 viz.py 1.15 "{}" shots/viz.png 2>&1 | tail -3
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 viz.py 1.15 "{}" shots/viz.png 2>&1 | tail -3result, 1 line
(Bash completed with no output)
Read~/Projects/lowmarch-fable52/review/out/whole-clips/shots/viz.png
input
{ "file_path": "~/Projects/lowmarch-fable52/review/out/whole-clips/shots/viz.png" }result
no output
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 k.py 0 "{}" "dict(fist=(-0.027,-0.17,-0.40))" "dict(fist=(-0.027,-0.15,-0.40), poleR=(0.8,-0.8,-0.4), poleL=(-0.8,-0.8,-0.4))" "dict(fist=(-0.027,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" "dict(fist=(-0.027,-0.15,-0.43), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" "dict(fist=(0.0,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" 2>&1 | tail -6 | cut -c1-200
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 k.py 0 "{}" "dict(fist=(-0.027,-0.17,-0.40))" "dict(fist=(-0.027,-0.15,-0.40), poleR=(0.8,-0.8,-0.4), poleL=(-0.8,-0.8,-0.4))" "dict(fist=(-0.027,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" "dict(fist=(-0.027,-0.15,-0.43), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" "dict(fist=(0.0,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2))" 2>&1 | tail -6 | cut -c1-200result, 6 lines
{} | RUpp -0.1 RLow 10.5 RHan 19.3 LUpp 2.2 LLow 8.0 LHan 11.8 | off 0.2 | elbR 110 E[ 0.1 -0.18 -0.14] elbL dict(fist=(-0.027,-0.17,-0.40)) | RUpp -1.0 RLow 9.3 RHan 24.7 LUpp 1.6 LLow 9.3 LHan 17.4 | off 0.1 | elbR 131 E[ 0.06 -0.17 -0.17] elbL dict(fist=(-0.027,-0.15,-0.40), poleR=(0.8,-0.8,-0.4), poleL=(-0.8,-0.8,-0.4)) | RUpp -0.4 RLow 9.9 RHan 24.5 LUpp 1.7 LLow 10.7 LHan 17.4 | off 0.2 | elbR 126 E[ 0.07 -0.16 -0.18] elbL dict(fist=(-0.027,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2)) | RUpp -0.4 RLow 9.9 RHan 24.6 LUpp 1.7 LLow 10.6 LHan 17.4 | off 0.2 | elbR 126 E[ 0.07 -0.16 -0.18] elbL dict(fist=(-0.027,-0.15,-0.43), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2)) | RUpp -1.1 RLow 9.2 RHan 27.2 LUpp 0.9 LLow 10.8 LHan 19.9 | off 0.1 | elbR 140 E[ 0.05 -0.15 -0.19] elbL dict(fist=(0.0,-0.15,-0.40), poleR=(1,-0.6,-0.2), poleL=(-1,-0.6,-0.2)) | RUpp 0.6 RLow 10.8 RHan 23.9 LUpp 0.8 LLow 8.8 LHan 17.1 | off 0.2 | elbR 122 E[ 0.09 -0.16 -0.17] elbLBashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && cat > g.py <<'EOF'
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && cat > g.py <<'EOF' import sys ARGV=list(sys.argv) import h, numpy as np v,shape=h.load(); sys.path.insert(0,h.ROOT+'/tools/whole') import clips2h f=clips2h.Fighter(v,shape) g=clips2h.Fighter.girdle for t in [float(x) for x in ARGV[2].split(',')]: k=clips2h.hermite(clips2h.ATTACK,t) if t>0 else clips2h.guard_at(0.0) for share in eval(ARGV[1]): f.girdle=lambda pose,side,target,share=share: g(f,pose,side,target,share,30) if share>=0 else pose p=f.solve(k) print(t, share, ' '.join(f"{n}{c*100:5.1f}" for n,c in f.body.clearance(p).items())) EOF OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 g.py "(-1,0.15,0.3,0.5)" 0,0.62,1.15 2>&1 | tail -12result, 12 lines
0.0 -1 R_UpperArm -1.0 R_LowerArm 6.0 R_Hand 19.0 L_UpperArm 1.3 L_LowerArm 6.5 L_Hand 11.5 0.0 0.15 R_UpperArm -0.1 R_LowerArm 9.2 R_Hand 19.2 L_UpperArm 1.8 L_LowerArm 7.5 L_Hand 11.6 0.0 0.3 R_UpperArm 0.3 R_LowerArm 11.3 R_Hand 19.4 L_UpperArm 2.2 L_LowerArm 8.1 L_Hand 11.8 0.0 0.5 R_UpperArm 0.5 R_LowerArm 11.7 R_Hand 19.4 L_UpperArm 1.7 L_LowerArm 7.6 L_Hand 11.9 0.62 -1 R_UpperArm -0.3 R_LowerArm 7.0 R_Hand 19.3 L_UpperArm 0.4 L_LowerArm 5.8 L_Hand 9.9 0.62 0.15 R_UpperArm 0.1 R_LowerArm 9.0 R_Hand 19.7 L_UpperArm -1.3 L_LowerArm 7.3 L_Hand 9.3 0.62 0.3 R_UpperArm 0.4 R_LowerArm 10.6 R_Hand 19.3 L_UpperArm -1.7 L_LowerArm 9.6 L_Hand 11.8 0.62 0.5 R_UpperArm 0.6 R_LowerArm 11.1 R_Hand 19.1 L_UpperArm -1.7 L_LowerArm 9.6 L_Hand 11.8 1.15 -1 R_UpperArm -1.8 R_LowerArm 5.1 R_Hand 17.4 L_UpperArm -0.4 L_LowerArm 3.8 L_Hand 7.0 1.15 0.15 R_UpperArm -1.5 R_LowerArm 7.6 R_Hand 16.7 L_UpperArm -0.8 L_LowerArm 3.6 L_Hand 8.0 1.15 0.3 R_UpperArm -1.1 R_LowerArm 8.9 R_Hand 16.1 L_UpperArm -1.6 L_LowerArm 5.1 L_Hand 9.8 1.15 0.5 R_UpperArm -1.0 R_LowerArm 9.3 R_Hand 15.9 L_UpperArm -1.7 L_LowerArm 5.2 L_Hand 9.9
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 k.py 0 "{}" "dict(turn=-5)" "dict(turn=4)" "dict(turn=-5, fist=(0.0,-0.15,-0.40))" "dict(turn=-5, fist=(0.0,-0.13,-0.40), hip=-15)" "dict(turn=-8, fist=(0.02,-0.15,-0.38), poleR=(1,-0.4,0))" 2>&1 | tail -6 | cut -c1-200
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 k.py 0 "{}" "dict(turn=-5)" "dict(turn=4)" "dict(turn=-5, fist=(0.0,-0.15,-0.40))" "dict(turn=-5, fist=(0.0,-0.13,-0.40), hip=-15)" "dict(turn=-8, fist=(0.02,-0.15,-0.38), poleR=(1,-0.4,0))" 2>&1 | tail -6 | cut -c1-200result, 6 lines
{} | RUpp -0.1 RLow 10.5 RHan 19.3 LUpp 2.2 LLow 8.0 LHan 11.8 | off 0.2 | elbR 110 E[ 0.1 -0.18 -0.14] elbL dict(turn=-5) | RUpp -0.1 RLow 10.5 RHan 19.1 LUpp 2.7 LLow 9.1 LHan 12.2 | off 0.2 | elbR 110 E[ 0.07 -0.19 -0.15] elbL dict(turn=4) | RUpp -0.1 RLow 10.4 RHan 19.0 LUpp 1.2 LLow 7.0 LHan 11.8 | off 0.1 | elbR 110 E[ 0.04 -0.2 -0.15] elbL dict(turn=-5, fist=(0.0,-0.15,-0.40)) | RUpp 0.3 RLow 10.6 RHan 23.8 LUpp 1.2 LLow 10.1 LHan 17.4 | off 0.1 | elbR 121 E[ 0.06 -0.17 -0.17] elbL dict(turn=-5, fist=(0.0,-0.13,-0.40), hip=-15) | RUpp 0.7 RLow 10.9 RHan 23.4 LUpp 1.3 LLow 10.5 LHan 17.2 | off 0.1 | elbR 117 E[ 0.07 -0.16 -0.17] elbL dict(turn=-8, fist=(0.02,-0.15,-0.38), poleR=(1,-0.4,0)) | RUpp 1.5 RLow 12.0 RHan 21.9 LUpp 1.0 LLow 8.6 LHan 15.4 | off 0.2 | elbR 112 E[ 0.1 -0.16 -0.16] elbLBashcd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF'
command
cd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF' s=open('clips2h.py').read() a="POLES = [(1.0, -0.5, 0.0), (0.6, -1.0, -0.4), (1.0, -0.2, 0.4)]" b="POLES = [(1.0, -0.5, 0.0), (1.0, -0.2, -0.5), (0.6, -1.0, -0.4), (1.0, -0.2, 0.4), (1.0, 0.3, -0.2)]" assert a in s; s=s.replace(a,b) s=s.replace("""GUARD = dict(drop=0.06, fwd=0.0, hip=-22.0, turn=-14.0, lean=6.0, lead=0.0, lift=0.0, fist=(-0.027, -0.166, -0.342), blade=(-0.05, 0.55, -0.83), poleR=(1.0, -0.7, 0.25),""","""GUARD = dict(drop=0.06, fwd=0.0, hip=-22.0, turn=-8.0, lean=6.0, lead=0.0, lift=0.0, fist=(0.02, -0.15, -0.38), blade=(-0.05, 0.55, -0.83), poleR=(1.0, -0.4, 0.0),""") s=s.replace("BREATH = dict(drop=0.075, lean=8.5, fist=(-0.027, -0.176, -0.338)","BREATH = dict(drop=0.075, lean=8.5, fist=(0.02, -0.16, -0.375)") open('clips2h.py','w').write(s) EOF grep -n "GUARD = \|BREATH =\|POLES =" clips2h.py; cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 t.py attack 2>&1 | grep -v "^ [~]" | cut -c1-250result, 41 lines
33:GUARD = dict(drop=0.06, fwd=0.0, hip=-22.0, turn=-8.0, lean=6.0, lead=0.0, lift=0.0, 36:BREATH = dict(drop=0.075, lean=8.5, fist=(0.02, -0.16, -0.375), blade=(-0.05, 0.50, -0.86)) # the low end 39:POLES = [(1.0, -0.5, 0.0), (1.0, -0.2, -0.5), (0.6, -1.0, -0.4), (1.0, -0.2, 0.4), (1.0, 0.3, -0.2)] solve 27.3s (setup 0.5s) wren: 34 keyframes checked; 1 with an arm through the body, 21 with an arm resting on it ! wren, attack at 1.15 s: left upper arm 1.2 cm inside the body; right upper arm 0.7 cm from the body idle 0.00 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 idle 0.20 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.8 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 idle 0.40 span 9.5 off 0.2 | hd 46.6 40.4 28.2 paul 33.7 legs 42.3 tip 1.46 | elb R 112 L 105 reach R0.43 L0.43 | hipext R-12 | RUpp 1.4 LUpp 1.0 idle 0.60 span 9.5 off 0.2 | hd 46.4 40.9 28.7 paul 33.6 legs 43.2 tip 1.49 | elb R 112 L 105 reach R0.43 L0.43 | hipext R-11 | RUpp 1.4 LUpp 1.0 idle 0.80 span 9.5 off 0.2 | hd 46.1 41.4 29.0 paul 33.6 legs 43.7 tip 1.52 | elb R 112 L 105 reach R0.43 L0.43 | hipext R -9 | RUpp 1.4 LUpp 1.0 idle 1.00 span 9.5 off 0.2 | hd 46.1 41.4 29.0 paul 33.6 legs 43.7 tip 1.53 | elb R 112 L 105 reach R0.43 L0.43 | hipext R -9 | RUpp 1.4 LUpp 1.0 idle 1.20 span 9.5 off 0.2 | hd 46.1 41.4 29.0 paul 33.6 legs 43.7 tip 1.52 | elb R 112 L 105 reach R0.43 L0.43 | hipext R -9 | RUpp 1.4 LUpp 1.0 idle 1.40 span 9.5 off 0.2 | hd 46.2 40.7 28.3 paul 33.7 legs 42.4 tip 1.48 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-12 | RUpp 1.4 LUpp 1.0 idle 1.60 span 9.5 off 0.2 | hd 46.6 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.0 idle 1.80 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 idle 2.00 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 attack 0.00 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 attack 0.10 span 9.5 off 0.1 | hd 36.1 36.2 26.8 paul 26.3 legs 42.6 tip 1.76 | elb R 89 L 92 reach R0.36 L0.39 | hipext R-13 | LUpp 1.6 attack 0.20 span 9.5 off 0.0 | hd 16.1 20.2 24.1 paul 15.2 legs 47.4 tip 2.08 | elb R 63 L 67 reach R0.26 L0.31 | hipext R-12 | LUpp 1.9 attack 0.26 span 9.5 off 0.0 | hd 12.9 15.6 22.6 paul 14.2 legs 50.2 tip 2.09 | elb R 59 L 57 reach R0.24 L0.29 | hipext R-14 | LUpp 1.7 attack 0.32 span 9.5 off 0.1 | hd 14.4 15.6 21.7 paul 15.4 legs 52.0 tip 1.92 | elb R 61 L 54 reach R0.24 L0.28 | hipext R-16 | attack 0.38 span 9.5 off 0.0 | hd 14.4 14.6 20.8 paul 15.3 legs 52.2 tip 1.83 | elb R 59 L 52 reach R0.22 L0.28 | hipext R-18 | LUpp 2.5 attack 0.44 span 9.5 off 0.0 | hd 13.9 14.0 20.2 paul 14.5 legs 51.9 tip 1.80 | elb R 56 L 50 reach R0.21 L0.27 | hipext R-18 | LUpp 1.7 attack 0.47 span 9.5 off 0.1 | hd 16.2 16.2 24.8 paul 16.4 legs 58.9 tip 2.14 | elb R 57 L 62 reach R0.24 L0.29 | hipext R-11 | attack 0.50 span 9.5 off 0.1 | hd 23.8 21.1 30.7 paul 19.2 legs 65.3 tip 2.15 | elb R 65 L 70 reach R0.29 L0.31 | hipext R 6 | LUpp 2.4 attack 0.53 span 9.5 off 0.1 | hd 38.1 25.2 30.2 paul 21.7 legs 62.4 tip 1.55 | elb R 88 L 87 reach R0.34 L0.36 | hipext R 15 | LUpp 1.5 attack 0.56 span 9.5 off 0.0 | hd 48.7 27.0 28.1 paul 25.6 legs 55.7 tip 0.70 | elb R 113 L 104 reach R0.39 L0.41 | hipext R 22 | LUpp 1.8 attack 0.59 span 9.5 off 0.1 | hd 49.0 26.9 27.1 paul 21.9 legs 46.9 tip 0.46 | elb R 108 L 94 reach R0.38 L0.39 | hipext R 23 | RUpp 2.6 attack 0.62 span 9.5 off 0.0 | hd 47.8 26.0 25.9 paul 19.3 legs 35.5 tip 0.29 | elb R 98 L 77 reach R0.36 L0.34 | hipext R 22 | RUpp 2.8 attack 0.65 span 9.5 off 0.1 | hd 38.2 26.4 26.7 paul 17.8 legs 18.9 tip 0.13 | elb R 91 L 103 reach R0.35 L0.32 | hipext R 21 | RUpp 1.3 LUpp 2.6 attack 0.68 span 9.5 off 0.0 | hd 31.4 25.2 25.3 paul 19.5 legs 12.1 tip 0.14 | elb R 86 L 87 reach R0.35 L0.31 | hipext R 21 | RUpp-0.1 attack 0.78 span 9.5 off 0.0 | hd 29.7 24.6 25.4 paul 19.4 legs 11.5 tip 0.17 | elb R 84 L 84 reach R0.35 L0.31 | hipext R 20 | RUpp 0.1 attack 0.90 span 9.5 off 0.0 | hd 31.2 26.3 26.2 paul 18.5 legs 12.9 tip 0.18 | elb R 82 L 86 reach R0.34 L0.31 | hipext R 20 | RUpp 0.5 attack 1.05 span 9.5 off 0.0 | hd 31.2 26.3 26.2 paul 18.5 legs 12.9 tip 0.18 | elb R 82 L 86 reach R0.34 L0.31 | hipext R 20 | RUpp 0.5 attack 1.15 span 9.5 off 0.1 | hd 42.4 31.5 18.0 paul 23.9 legs 24.1 tip 0.36 | elb R 101 L 93 reach R0.37 L0.34 | hipext R 11 | RUpp 0.7 LUpp-1.2 attack 1.25 span 9.5 off 0.2 | hd 49.8 36.8 22.7 paul 31.9 legs 34.2 tip 1.04 | elb R 111 L 101 reach R0.42 L0.41 | hipext R -0 | RUpp 1.7 LUpp 0.8 attack 1.35 span 9.5 off 0.2 | hd 48.8 39.0 26.5 paul 34.5 legs 38.6 tip 1.26 | elb R 115 L 107 reach R0.43 L0.43 | hipext R -8 | RUpp 2.2 LUpp 0.6 attack 1.42 span 9.5 off 0.2 | hd 47.5 39.8 27.5 paul 34.0 legs 40.7 tip 1.38 | elb R 113 L 107 reach R0.43 L0.43 | hipext R-12 | RUpp 1.3 LUpp 0.8 attack 1.50 span 9.5 off 0.2 | hd 46.7 40.1 27.9 paul 33.8 legs 41.7 tip 1.44 | elb R 112 L 106 reach R0.43 L0.43 | hipext R-14 | RUpp 1.4 LUpp 1.1 total 39s
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 1.15 "{}" '{"x":(-0.02,0.08),"y":(-0.18,-0.10),"z":(-0.40,-0.30),"turn":(12,22),"lean":(12,18),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3),(-1,0,0))}' 40 2>&1 | tail -4
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 1.15 "{}" '{"x":(-0.02,0.08),"y":(-0.18,-0.10),"z":(-0.40,-0.30),"turn":(12,22),"lean":(12,18),"poleL":((-1,-0.4,0.4),(-0.8,-1,0.2),(-1,-0.6,-0.3),(-1,0,0))}' 40 2>&1 | tail -4result, 4 lines
{'x': 0.016, 'y': -0.129, 'z': -0.362, 'turn': 15.815, 'lean': 15.023, 'poleL': (-1, 0, 0)} | clear 0.5 (L_UpperArm) off 0.1 miss 0.1 elb R 113 L 95 fist [-0.09 0.93 -0.53] {'x': -0.005, 'y': -0.103, 'z': -0.360, 'turn': 14.952, 'lean': 17.082, 'poleL': (-1, -0.6, -0.3)} | clear 0.2 (L_UpperArm) off 0.0 miss 0.1 elb R 111 L 104 fist [-0.1 0.94 -0.54] {'x': 0.064, 'y': -0.122, 'z': -0.363, 'turn': 16.484, 'lean': 14.206, 'poleL': (-1, -0.4, 0.4)} | clear 0.2 (L_UpperArm) off 0.1 miss 0.0 elb R 105 L 97 fist [-0.04 0.94 -0.55] {'x': -0.019, 'y': -0.128, 'z': -0.328, 'turn': 20.356, 'lean': 13.691, 'poleL': (-0.8, -1, 0.2)} | clear 0.1 (R_UpperArm) off 0.0 miss 0.1 elb R 109 L 93 fist [-0.13 0.95 -0.48]Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 python3 -c "
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 python3 -c " import sys; sys.path[:0]=['~/Projects/lowmarch-fable52/tools/whole','~/Projects/lowmarch-fable52/tools'] import clips2h k=clips2h.hermite(clips2h.ATTACK,1.15) print({n:(round(float(v),3) if v.ndim==0 else tuple(round(float(x),3) for x in v)) for n,v in k.items()}) "result, 1 line
{'drop': 0.098, 'fwd': 0.119, 'hip': 4.444, 'turn': 16.778, 'lean': 14.667, 'lead': 0.237, 'lift': 0.02, 'fist': (0.008, -0.138, -0.314), 'blade': (-0.5, -0.425, -0.212), 'poleR': (1.0, -0.4, 0.0), 'poleL': (-0.911, -0.667, 0.311), 'gaze': -0.06}Edit~/Projects/lowmarch-fable52/tools/whole/clips2h.py
input
~/Projects/lowmarch-fable52/tools/whole/clips2h.py - (1.25, key(drop=0.08, + (1.15, key(drop=0.10, fwd=0.12, hip=4.0, turn=16.0, lean=15.0, lead=0.24, lift=0.02, fist=(0.016, -0.129, -0.362), + blade=(-0.50, -0.42, -0.22), poleL=(-1.0, 0.0, 0.0)), False), + (1.25, key(drop=0.08,
result, 1 line
The file ~/Projects/lowmarch-fable52/tools/whole/clips2h.py has been updated successfully. (note: the file had been modified on disk since you last read it — the edit applied cleanly, but the file contains other changes not in your context. Read it before edits that depend on surrounding content.)
BashTAG=b ~/Projects/lowmarch-fable52/review/out/whole-clips/shots.sh 2>&1 | grep -v "^\s*~" | tail -12 && cd ~/Projects/lowmarch-fable52/review/out/whole-clips && python3 sheet.py b shots/b_sheet.png 0.6
command
TAG=b ~/Projects/lowmarch-fable52/review/out/whole-clips/shots.sh 2>&1 | grep -v "^\s*~" | tail -12 && cd ~/Projects/lowmarch-fable52/review/out/whole-clips && python3 sheet.py b shots/b_sheet.png 0.6
result, 13 lines
wren: 34 keyframes checked; no arm through the body, 22 with an arm resting on it -> ~/Projects/lowmarch-fable52/review/out/whole-clips/site 43s build 42s review/out/whole-clips/shots/b_attack_0.68.png 20s review/out/whole-clips/shots/b_idle_1.0.png 21s review/out/whole-clips/shots/b_attack_1.30.png 21s review/out/whole-clips/shots/b_attack_0.38.png 21s review/out/whole-clips/shots/b_attack_0.20.png 21s review/out/whole-clips/shots/b_attack_0.90.png 21s review/out/whole-clips/shots/b_idle_0.0.png 22s review/out/whole-clips/shots/b_attack_0.56.png 22s shoot 23s shots/b_sheet.png (1158, 1314)
Read~/Projects/lowmarch-fable52/review/out/whole-clips/shots/b_sheet.png
input
{ "file_path": "~/Projects/lowmarch-fable52/review/out/whole-clips/shots/b_sheet.png" }result
no output
Bashcd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.68 "{}" '{"x":(-0.12,0.06),"y":(-0.24,-0.06),"z":(-0.40,-0.18),"turn":(15,45),"lean":(10,26),"bx":(-0.6,-0.3),"by":(-0.75,-0.5),"bz":(0.5,0.8),"poleL":((-1,-0.4,0.4),(-1,0,0),(-1,-0.6,-0.3))}' 120 2>&1 | tail -8
command
cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 rnd.py 0.68 "{}" '{"x":(-0.12,0.06),"y":(-0.24,-0.06),"z":(-0.40,-0.18),"turn":(15,45),"lean":(10,26),"bx":(-0.6,-0.3),"by":(-0.75,-0.5),"bz":(0.5,0.8),"poleL":((-1,-0.4,0.4),(-1,0,0),(-1,-0.6,-0.3))}' 120 2>&1 | tail -8result, 8 lines
{'x': 0.025, 'y': -0.067, 'z': -0.367, 'turn': 29.466, 'lean': 24.315, 'bx': -0.473, 'by': -0.603, 'bz': 0.507, 'poleL': (-1, 0, 0)} | clear 2.1 (R_UpperArm) off 0.1 miss 0.1 elb R 92 L 139 fist [-0.18 0.9 -0.59] {'x': 0.047, 'y': -0.085, 'z': -0.333, 'turn': 16.167, 'lean': 22.291, 'bx': -0.528, 'by': -0.667, 'bz': 0.674, 'poleL': (-1, -0.6, -0.3)} | clear 2.0 (L_UpperArm) off 0.0 miss 0.1 elb R 81 L 134 fist [-0.06 0.91 -0.59] {'x': 0.054, 'y': -0.158, 'z': -0.216, 'turn': 16.676, 'lean': 16.169, 'bx': -0.432, 'by': -0.595, 'bz': 0.575, 'poleL': (-1, 0, 0)} | clear 2.0 (L_UpperArm) off 0.1 miss 0.1 elb R 66 L 89 fist [-0.02 0.91 -0.45] {'x': 0.019, 'y': -0.145, 'z': -0.265, 'turn': 16.017, 'lean': 12.989, 'bx': -0.398, 'by': -0.607, 'bz': 0.548, 'poleL': (-1, 0, 0)} | clear 1.8 (L_UpperArm) off 0.0 miss 0.0 elb R 77 L 103 fist [-0.06 0.93 -0.49] {'x': -0.004, 'y': -0.139, 'z': -0.209, 'turn': 20.920, 'lean': 11.665, 'bx': -0.482, 'by': -0.716, 'bz': 0.667, 'poleL': (-1, -0.6, -0.3)} | clear 1.8 (R_UpperArm) off 0.1 miss 0.1 elb R 68 L 81 fist [-0.09 0.95 -0.42] {'x': 0.008, 'y': -0.110, 'z': -0.223, 'turn': 23.136, 'lean': 20.027, 'bx': -0.359, 'by': -0.528, 'bz': 0.772, 'poleL': (-1, -0.6, -0.3)} | clear 1.8 (L_UpperArm) off 0.1 miss 0.1 elb R 64 L 91 fist [-0.1 0.94 -0.46] {'x': 0.029, 'y': -0.096, 'z': -0.327, 'turn': 25.208, 'lean': 11.769, 'bx': -0.466, 'by': -0.723, 'bz': 0.663, 'poleL': (-1, 0, 0)} | clear 1.7 (R_UpperArm) off 0.0 miss 0.1 elb R 83 L 126 fist [-0.12 0.97 -0.54] {'x': 0.030, 'y': -0.072, 'z': -0.302, 'turn': 36.903, 'lean': 16.891, 'bx': -0.516, 'by': -0.587, 'bz': 0.784, 'poleL': (-1, 0, 0)} | clear 1.6 (R_UpperArm) off 0.0 miss 0.1 elb R 73 L 121 fist [-0.17 0.97 -0.51]Bashcd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF'
command
cd ~/Projects/lowmarch-fable52/tools/whole && python3 - <<'EOF' s=open('clips2h.py').read() rep=[(""" (0.68, key(drop=0.12, fwd=0.17, hip=14.0, turn=25.0, lean=19.6, lead=0.30, fist=(-0.013, -0.12, -0.284), blade=(-0.51, -0.83, 0.28), poleL=(-1.0, -0.4, 0.4)), False),""", """ (0.68, key(drop=0.12, fwd=0.17, hip=14.0, turn=29.5, lean=24.0, lead=0.30, fist=(0.025, -0.067, -0.367), blade=(-0.47, -0.60, 0.51), poleL=(-1.0, 0.0, 0.0)), False),"""), (""" (0.9, key(drop=0.11, fwd=0.16, hip=13.0, turn=24.0, lean=18.0, lead=0.30, fist=(-0.01, -0.11, -0.28), blade=(-0.50, -0.80, 0.30), poleL=(-1.0, -0.4, 0.4)), True), (1.05, key(drop=0.11, fwd=0.16, hip=13.0, turn=24.0, lean=18.0, lead=0.30, fist=(-0.01, -0.11, -0.28), blade=(-0.50, -0.80, 0.30), poleL=(-1.0, -0.4, 0.4)), True),""", """ (0.9, key(drop=0.11, fwd=0.16, hip=13.0, turn=25.0, lean=14.0, lead=0.30, fist=(0.029, -0.096, -0.327), blade=(-0.47, -0.72, 0.66), poleL=(-1.0, 0.0, 0.0)), True), (1.05, key(drop=0.11, fwd=0.16, hip=13.0, turn=25.0, lean=14.0, lead=0.30, fist=(0.029, -0.096, -0.327), blade=(-0.47, -0.72, 0.66), poleL=(-1.0, 0.0, 0.0)), True),"""), ] for a,b in rep: assert s.count(a)==1,a[:40]; s=s.replace(a,b) open('clips2h.py','w').write(s) EOF cd ~/Projects/lowmarch-fable52/review/out/whole-clips && OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 python3 k.py 0.2 "{}" "dict(fist=(0.10,-0.03,-0.22), blade=(0.35,0.92,0.12))" "dict(fist=(0.12,0.0,-0.22), blade=(0.40,0.88,0.20))" "dict(fist=(0.12,0.0,-0.22), blade=(0.40,0.88,0.20), poleR=(1,-0.6,0.2), poleL=(-0.2,-0.8,-1))" 2>&1 | tail -4 | cut -c1-200result, 4 lines
{} | RUpp 4.7 RLow 7.0 RHan 8.0 LUpp 1.9 LLow 3.9 LHan 6.6 | off 0.0 | elbR 63 E[ 0.21 -0.12 -0.08] elbL dict(fist=(0.10,-0.03,-0.22), blade=(0.35,0.92,0.12)) | RUpp 6.7 RLow 8.2 RHan 3.8 LUpp 1.4 LLow 7.3 LHan 7.7 | off 0.1 | elbR 59 E[ 0.23 -0.09 0. ] elbL dict(fist=(0.12,0.0,-0.22), blade=(0.40,0.88,0.20)) | RUpp 7.3 RLow 8.8 RHan 4.7 LUpp 2.0 LLow 7.9 LHan 6.9 | off 0.1 | elbR 56 E[ 0.23 -0.09 0.02] elbL dict(fist=(0.12,0.0,-0.22), blade=(0.40,0.88,0.20), poleR=(1,-0.6,0.2), poleL=(-0.2,-0.8,- | RUpp 6.4 RLow 7.5 RHan 5.5 LUpp 2.1 LLow 7.9 LHan 6.8 | off 0.1 | elbR 52 E[ 0.21 -0.13 0.04] elbL


