Compare commits

..

6 Commits

Author SHA1 Message Date
503e624b3f add 9 movers 2025-06-02 21:11:17 +03:00
6dd45363e7 buh 2025-05-31 21:14:03 +03:00
074878ee9f change settings 2024-09-12 17:05:53 +03:00
e3b065ff53 this never worked lol 2024-08-31 10:18:44 +03:00
acf43781b2 add custom regrip for F floating 2024-08-30 20:52:24 +03:00
0a1c25460e U2' feido 2024-08-25 20:29:19 +03:00
10 changed files with 609 additions and 32 deletions

View File

@ -20,10 +20,10 @@ from scorer import (
import heapq
from typing import List, Any, Generator, Dict
SOLUTIONS_TO_EVAL = 1000
SOLUTIONS_TO_EVAL = 100
SOLUTIONS_TO_SHOW = 3
PRUNE = 10
PRUNE = 9
SOLVE = 7
@ -71,7 +71,7 @@ def main():
# list(EOLROrientation), EOLR_PERMUTATIONS
# )
eolrb_states, n_states = eolrb_states_generator(
[EOLROrientation.OneOne], EOLR_PERMUTATIONS
list(EOLROrientation), EOLR_PERMUTATIONS
)
for i, (eolrb_cube, ori, perm, pre_auf) in enumerate(eolrb_states):
print(

View File

@ -15,7 +15,7 @@ def main():
continue
if case.startswith("Solved"):
continue
if not case.startswith("OneOne"):
if "Arrow" in case:
continue
print(f'{case}: "{scramble['alg']}"')
covered_cases.add(scramble["raw_alg"])

View File

@ -211,9 +211,6 @@ def condense_algorithm(moves: List[str]) -> List[str]:
return result
reduced_moves = apply_reduction(moves)
# print(reduced_moves)
counted_moves = reduce_moves(reduced_moves)
# print(counted_moves)
reduced_alg = build_reduced_alg(counted_moves)
# print(reduced_alg)
return reduced_alg

View File

@ -50,7 +50,13 @@ fingers:
- DF
- F
- F floating
regrips: []
regrips:
- start: F floating
end: F
score: 2
# F floating is hard
# TODO: this doesn't need to be here
finger: pinky
finger_tricks:
- name: "U push"
move: "U"
@ -59,7 +65,7 @@ finger_tricks:
grip_post:
index: B
grip_pre_blacklist: {}
score: 5
score: 1001
- name: "U flick"
move: "U"
grip_pre:
@ -68,7 +74,7 @@ finger_tricks:
# TODO: rethink this parameter
index: LB
grip_pre_blacklist: {}
score: 4
score: 1001
- name: "U' push"
move: "U'"
grip_pre:
@ -76,7 +82,7 @@ finger_tricks:
grip_post:
index: F
grip_pre_blacklist: {}
score: 5
score: 1000
- name: "U' flick"
move: "U'"
grip_pre:
@ -84,15 +90,15 @@ finger_tricks:
grip_post:
index: LF
grip_pre_blacklist: {}
score: 3
- name: "U2 feido"
score: 1000
- name: "U2' feido"
move: "U2"
grip_pre:
index: BL
grip_post:
index: F
grip_pre_blacklist: {}
score: 5
score: 1002
- name: "U2 double flick"
move: "U2"
grip_pre:
@ -100,7 +106,7 @@ finger_tricks:
grip_post:
index: LF
grip_pre_blacklist: {}
score: 6
score: 1002
- name: "U2' double flick"
move: "U2"
grip_pre:
@ -108,7 +114,7 @@ finger_tricks:
grip_post:
index: BL
grip_pre_blacklist: {}
score: 9
score: 1002
- name: "U2 beido"
move: "U2"
grip_pre:
@ -116,7 +122,7 @@ finger_tricks:
grip_post:
index: B
grip_pre_blacklist: {}
score: 5
score: 1002
- name: "M' ring flick"
move: "M'"
grip_pre:
@ -124,7 +130,7 @@ finger_tricks:
grip_post:
ring: DF
grip_pre_blacklist: {}
score: 3
score: 1000
- name: "M' pinky flick"
move: "M'"
# I can't do M' after finishing beido
@ -136,7 +142,7 @@ finger_tricks:
index:
- BL
- UF
score: 6
score: 1000
- name: "M push"
move: "M"
grip_pre:
@ -144,7 +150,7 @@ finger_tricks:
grip_post:
pinky: DB
grip_pre_blacklist: {}
score: 5
score: 1001
- name: "M index push"
move: "M"
grip_pre:
@ -152,7 +158,7 @@ finger_tricks:
grip_post:
index: UF
grip_pre_blacklist: {}
score: 6
score: 1001
- name: "M2 double flick"
move: "M2"
grip_pre:
@ -162,4 +168,4 @@ finger_tricks:
pinky: F floating
ring: DB
grip_pre_blacklist: {}
score: 7
score: 1002

149
roux_7_movers.txt Normal file
View File

@ -0,0 +1,149 @@
U' M U' M' U' M' U' M' U' M2
M' U' M' U M U2 M U'
U M' U2 M U M' U M U'
M' U' M' U' M U2 M U'
U' M' U2 M U' M' U' M U'
M' U' M' U' M' U2 M U M2
M' U' M' U2 M' U2 M U M2
M' U' M U2 M' U2 M' U' M2
M' U' M' U' M U2 M' U' M2
M' U' M' U' M' U2 M' U
M' U' M' U2 M U2 M' U M2
U M U M' U M' U M U'
M' U' M' U2 M' U2 M' U'
U' M U' M' U' M' U' M U
M' U' M' U M' U2 M' U
M' U' M' U M U2 M' U' M2
M' U' M U' M' U2 M' U' M2
M' U' M U' M U2 M' U
M' U' M U M' U2 M U
U' M U' M' U' M' U M' U' M2
M' U' M U' M U2 M U' M2
M' U' M U' M' U2 M U
U' M' U2 M U' M' U M' U' M2
M' U' M U M U2 M' U
M' U' M U M' U2 M' U' M2
M' U M' U2 M' U2 M U' M2
U M' U M' U' M' U' M' U'
U2 M U' M U M' U2 M' U
U2 M U' M' U2 M' U2 M U'
U2 M U M' U2 M' U2 M U'
U M' U2 M' U M' U M U' M2
U2 M U' M U' M' U2 M' U
U' M' U2 M' U' M' U' M U' M2
U2 M U' M U' M U2 M' U' M2
U2 M U' M U' M' U2 M U M2
U' M' U2 M' U' M' U M'
U2 M U' M' U2 M U2 M' U'
U' M' U M U M U M' U
U2 M U M' U2 M' U2 M' U' M2
U M' U' M U' M U' M' U'
U M' U M' U' M' U' M U' M2
U2 M U M' U M U2 M' U'
U2 M U' M' U' M U2 M U M2
U2 M U' M' U' M' U2 M U'
U2 M U' M' U M U2 M' U'
U' M' U' M' U M' U M U' M2
U2 M U' M' U' M U2 M' U'
U M' U' M U' M U M'
U2 M U' M' U M U2 M U' M2
U2 M U' M' U M' U2 M U
U2 M U' M U M' U2 M U' M2
M' U2 M U2 M' U' M' M2
M' U2 M' U2 M' U' M' U2
U M' U2 M' U2 M' U' M U M2
U M' U2 M' U2 M' U M U' M2
M U' M U' M' U' M U' M2
M' U' M U' M' U M U
M U' M U' M' U M U' M2
M' U' M U' M' U' M' U' M2
M' U M U M' U M' U' M2
M' U M U M' U' M' U2 M2
M U' M U' M' U M' U'
U M U' M' U2 M' U M U
M' U' M U' M' U' M U
U M U' M U2 M' U M' U
M U M U M' U' M' U2
M' U' M U' M' U M' U' M2
M U M U M' U M' U
M U' M U' M' U' M' U
U M U' M' U2 M' U M' U2 M2
U M U' M' U2 M' U' M' U' M2
M' U M U M' U M U
U' M U M' U2 M' U M U'
U2 M' U' M' U' M U' M' U M2
U' M' U' M' U2 M U' M' U M2
U M' U M' U2 M U M' U M2
U2 M U' M' U' M U M' U'
U2 M' U' M' U' M U M' U M2
U2 M U M' U M U' M'
U2 M' U' M' U' M U M U
U' M' U' M U2 M U M' U'
U' M' U' M' U2 M U M U'
U2 M' U M' U M U' M' M2
U2 M U' M' U' M U M U M2
U2 M U' M' U' M U' M' U'
U2 M' U M' U M U M U'
U' M' U' M' U2 M U M' U2 M2
U2 M' U' M' U' M U' M U'
U2 M' U M' U M U' M U
U2 M U M' U M U' M U M2
U M' U M U2 M U M' U
U2 M U M' U M U M' U'
U' M2 U' M U' M2 U M' U2
U' M2 U' M U2 M2 U M' U2
M' U' M' U' M' U M'
U2 M' U2 M' U' M U M U
M' U M U' M U' M' U'
U M' U2 M' U M U M' M2
U2 M U M' U' M' U' M U
U' M' U M' U M' U' M' U
U' M' U2 M U' M U' M' U'
M' U' M' U' M' U' M' U'
U M' U2 M' U M U' M U'
U2 M' U2 M' U' M U M' M2
U' M' U' M U M U M' U'
U M U' M' U M' U M U
U2 M' U2 M' U' M U' M' U M2
M' U2 M U M U M' U
U M' U2 M' U M U' M' M2
M' U' M' U' M' U' M U' M2
U M U M U M U M' U' M2
U2 M U' M U' M U' M' U' M2
U' M' U M' U M' U M U' M2
U' M' U M' U2 M' U M' U
U M U M' U2 M U' M' U
M' U' M' U2 M' U M' U
U' M' U M U2 M' U M' U2 M2
M' U' M' U2 M' U' M' U
U2 M U' M' U2 M U M' U
U2 M U' M' U2 M U M U M2
M' U' M U2 M' U M' U' M2
U M U M U2 M U M' U' M2
U' M' U M' U2 M' U M U M2
U M U M' U2 M U M U' M2
M' U' M' U2 M' U M U M2
U2 M U' M U2 M U M' U M2
U' M U2 M' U2 M' U' M' U' M2
U' M' U2 M' U2 M U M U'
U M' U2 M' U2 M U' M' U M2
U2 M' U M U' M' U' M U'
M' U' M U M' U' M U
M' U M U' M' U M U
U2 M U' M' U M U M U M2
U2 M U M' U' M U' M U M2
M' U' M U M' U M' U' M2
M' U M U' M' U' M' U' M2
M' U' M U M' U M U
U2 M' U' M U M' U' M' U2 M2
M U M' U' M U M U M2
M U' M' U M U' M'
U2 M U M' U' M U' M'
U M' U' M' U M U' M' M2
U2 M' U M' U' M U' M' U2 M2
U M' U' M' U M U M
U2 M U' M U M' U M' U
U2 M U M U' M' U' M' U
U' M U M U' M' U' M U M2
M' U M' U' M U' M U'
U2

183
roux_9_movers.txt Normal file
View File

@ -0,0 +1,183 @@
U M' U' M2 U M' U' M U' M U M2
U M' U' M2 U' M' U M U M U M2
M U' M2 U' M' U2 M' U2 M' U
M' U' M' U2 M U2 M' U' M2 U'
U M' U M2 U' M U' M' U M' U'
U M2 U' M U M' U' M' U' M U' M2
U M2 U M' U' M' U' M' U M' U' M2
M' U' M U' M2 U' M' U2 M U' M2
U M' U' M2 U' M' U M U' M U' M2
M' U' M' U' M2 U M U2 M' U'
M' U' M' U' M2 U M' U2 M' U M2
M' U M U' M2 U' M' U2 M U' M2
M' U' M' U' M2 U' M' U2 M' U' M2
U M' U' M2 U M' U' M U' M' U
M' U' M U' M U2 M' U' M2 U' M2
U M' U' M U' M' U M2 U M U' M2
U M' U' M' U' M2 U M' U M U
U2 M' U' M2 U' M' U2 M' U2 M' U' M2
U2 M' U' M2 U' M U2 M' U2 M U M2
U M2 U' M U' M' U M' U M U' M2
U2 M' U' M2 U' M' U' M' U2 M U
U M' U M' U' M U' M2 U M' U'
U2 M' U' M2 U' M' U M U2 M U' M2
U2 M' U' M2 U' M' U M U2 M' U
U2 M' U' M2 U' M' U M' U2 M' U' M2
U M' U' M U' M' U M2 U' M' U
U M' U2 M' U M U M2 U' M' U2
U' M2 U' M' U' M' U' M' U M' U' M2
U' M' U' M U' M2 U' M' U M' U
M U2 M U2 M' U' M2 U' M' U2 M2
M U2 M' U2 M' U' M2 U' M'
U' M' U2 M' U2 M' U' M U' M2 U'
U M' U2 M' U2 M' U' M2 U2 M' U M2
U' M' U2 M' U2 M' U' M U M2 U'
U M' U2 M' U2 M' U' M' U' M2 U M2
U M' U2 M U2 M' U' M2 U2 M' U
U M' U2 M' U2 M' U' M' U M2 U M2
U M' U2 M' U2 M' U' M U2 M2 U'
U M' U2 M U2 M' U' M U M2 U' M2
U M' U2 M U2 M' U' M U' M2 U' M2
U M' U2 M U2 M' U' M U2 M2 U' M2
U' M' U' M2 U' M' U2 M U M U' M2
U' M' U2 M2 U M' U2 M U M' U
M' U' M2 U M' U M' U M U'
M' U' M2 U' M U M U' M' U M2
M' U' M U' M' U M' U M2 U
M' U' M' U' M2 U M U M' U'
M' U' M U' M U M2 U M' U M2
M U M2 U' M' U' M' U M'
M U' M' U' M2 U M U' M' U' M2
U' M' U' M2 U' M' U2 M U' M' U
U M' U2 M2 U' M' U2 M U M U M2
U M' U M2 U M' U2 M U M' U'
M' U' M U' M' U' M' U2 M2 U
M' U' M U' M U M2 U M U'
M' U' M' U' M2 U M U M U M2
M' U' M' U' M2 U M U' M' U'
M' U' M2 U' M U M U M' U' M2
U M' U2 M2 U' M' U2 M U' M' U'
U M U' M' U2 M U M2 U M' U M2
M' U' M U' M U' M2 U M' M2
M' U' M U' M U2 M2 U' M' U2 M2
M' U M' U' M2 U' M' U M' U' M2
M' U M' U2 M2 U M U' M' U'
M' U M' U M2 U' M U' M U M2
M' U2 M2 U' M' U M U' M'
U2 M' U' M U' M2 U M' U M' U
U2 M' U' M' U' M U M2 U2 M' U'
U2 M' U' M' U' M' U M2 U M' U' M2
M2 U' M U' M U2 M' U' M' M2
U2 M' U' M2 U' M' U M' U M' U' M2
U2 M' U' M' U' M U M U M2 U M2
U2 M' U' M U' M2 U M' U' M' U
U2 M' U' M' U' M U' M2 U2 M U' M2
U2 M' U' M' U' M' U M2 U' M' U M2
U M2 U' M' U' M U2 M' U' M' U'
U' M2 U2 M' U' M U2 M' U' M' U
U' M' U' M' U2 M' U M2 U M U'
U2 M U' M' U' M' U M2 U' M' U
U2 M U' M' U' M U M2 U2 M' U M2
U2 M U' M' U' M' U M2 U M' U
U2 M U' M U' M2 U M' U M' U' M2
U2 M U' M2 U' M' U M' U M U M2
U M2 U2 M' U M' U2 M' U M' U' M2
U2 M' U M U M2 U' M' U' M' U'
M2 U' M U' M' U2 M' U' M U' M2
U2 M U' M' U' M' U2 M2 U' M'
U2 M' U' M' U' M' U2 M2 U' M' M2
U2 M' U' M2 U' M' U M' U M U
U2 M U M U2 M2 U M' U' M U
U2 M U M U M2 U' M' U' M' U' M2
M' U' M' U' M U M2 U M'
U M' U' M2 U' M U M' U M' U
U M' U' M2 U' M U M' U' M' U
U' M2 U' M' U' M U M' U2 M U' M2
M2 U M' U' M U' M' U2 M U' M2
U' M2 U' M' U' M' U' M U2 M' U
U M2 U' M U' M U' M' U2 M' U' M2
U' M2 U' M' U' M' U' M' U2 M U'
U' M' U' M U M' U' M2 U' M' U
U' M2 U' M' U' M U' M' U2 M U' M2
M' U' M' U' M' U' M2 U2 M' U' M2
M' U' M' U' M' U M U M2 U
M' U' M' U' M U M2 U' M'
M2 U M' U' M' U' M U2 M U' M2
M2 U M' U' M' U' M' U2 M U
U M2 U' M U' M' U2 M' U2 M U M2
M2 U M' U' M U2 M' U2 M' U'
U' M2 U' M' U' M U2 M' U2 M' U
M2 U M' U' M' U2 M' U2 M U
M' U' M' U' M' U M U2 M2 U'
U M2 U M U' M' U' M U M' U' M2
U2 M2 U' M' U' M' U' M U M' U'
U M2 U M' U' M' U' M U M' U
M2 U' M' U' M U' M' U M U' M2
U2 M2 U' M U' M' U' M U' M' U M2
U' M' U M' U2 M' U' M2 U2 M' U' M2
M2 U' M' U M U M' U M U' M2
U M' U' M2 U' M' U2 M' U' M U'
U' M2 U2 M U' M' U2 M' U' M' U
U2 M2 U' M U M' U M U M' U M2
U M' U' M2 U' M' U2 M' U' M' M2
U M' U' M2 U' M U2 M' U' M' U2
U' M2 U M' U' M U' M' U' M U' M2
U2 M2 U' M' U' M' U' M U' M' U
M' U' M' U2 M U M2 U M' U'
U M2 U M U' M' U' M U' M' U M2
M2 U' M U' M U' M' U' M U'
U2 M U' M U2 M' U M2 U M U
M2 U' M U' M U' M' U M' U2 M2
U2 M' U2 M2 U' M U2 M' U' M' U'
U2 M' U M2 U M' U2 M' U M' U' M2
M2 U' M' U' M U' M' U M' U
M' U' M' U2 M U M2 U M U' M2
M' U' M' U2 M U M2 U' M'
U M' U2 M2 U M U2 M' U M' U'
U M2 U2 M' U' M U2 M U' M' U' M2
U' M2 U M U' M U' M' U M' U2 M2
U' M' U M' U2 M' U M U2 M2 U'
M2 U2 M U M' U2 M' U M' U'
U M' U2 M' U2 M' U' M2 U' M' U M2
U M U2 M U2 M' U' M2 U2 M' U M2
U M' U2 M U2 M' U' M2 U M' U
M2 U' M U2 M' U2 M' U' M' U2
U M2 U' M' U2 M U2 M' U' M'
M2 U' M U2 M U2 M' U' M' M2
U' M2 U' M' U2 M' U2 M' U' M' M2
U' M' U2 M U2 M' U' M2 U' M' U'
U M' U2 M' U2 M U M2 U2 M' U'
U M' U2 M' U2 M' U' M2 U M U
U2 M2 U' M U2 M' U2 M' U M U' M2
U' M2 U' M' U2 M U2 M' U' M U' M2
U2 M2 U' M U2 M' U2 M' U' M U' M2
U M2 U' M' U2 M' U2 M' U' M U'
M2 U M U2 M U2 M' U' M' U M2
U M' U2 M' U2 M U' M U2 M2 U' M2
U M' U2 M' U2 M' U' M2 U M' U' M2
U M U2 M' U2 M' U' M2 U2 M' U'
U M U2 M' U2 M' U' M U2 M2 U M2
U M' U2 M U2 M' U' M2 U M U M2
U M2 U M' U2 M U2 M' U' M' U'
U' M2 U M' U2 M' U2 M' U' M' U' M2
M' U' M2 U' M' U' M' U' M U'
U M2 U' M' U M U' M' U' M' U'
U2 M' U M U' M U' M2 U M' U' M2
M2 U' M' U' M' U M U' M' U
M' U' M2 U' M' U' M' U M U'
U2 M U M' U' M' U' M2 U M' U
M2 U' M' U' M' U M U M' U
M2 U' M' U M' U' M U' M' U
U2 M2 U' M U' M U M' U M U'
M' U' M' U2 M2 U M U' M' U'
M2 U' M' U' M' U M U M U' M2
M' U' M' U' M2 U' M' U M' U' M2
U2 M' U' M2 U' M' U' M' U M' M2
U M2 U' M' U' M U M' U' M' U'
M' U' M2 U' M U' M U M' M2
M' U2 M2 U M' U M U M M2
M' U2 M2 U M' U M U' M'
U2 M' U' M2 U M' U' M' U' M' U M2
M' U' M U M2 U' M' U' M U' M2
U M' U M' U' M' U' M2 U M' M2
U2

24
roux_trainer.py Normal file
View File

@ -0,0 +1,24 @@
import json
def main():
with open("./output.json") as f:
data = json.loads(f.read())
covered_cases = set()
for case, scrambles in data.items():
if not scrambles:
continue
scramble = scrambles[0]
if scramble["raw_alg"] in covered_cases:
continue
if scramble["stm"] != 9:
continue
if case.startswith("Solved"):
continue
print(scramble["alg"])
covered_cases.add(scramble["raw_alg"])
print("U2")
if __name__ == "__main__":
main()

View File

@ -1,4 +1,4 @@
from typing import Dict, List
from typing import Dict, List, Set, Tuple
import yaml
import dacite
from dataclasses import dataclass
@ -52,23 +52,61 @@ class Definitions:
finger_regrips: List[Regrip]
def build_missing_regrips(
finger_regrips: Dict[Tuple[str, str], Regrip], finger: Finger, grips: Set[str]
) -> Dict[Tuple[str, str], Regrip]:
# this might just be the worst piece of code I have ever written
# fill in missing regrips so every pair of grips has a regrip
for grip_start in grips:
for grip_end in grips:
if grip_start != grip_end:
if (grip_start, grip_end) not in finger_regrips:
# TODO: this only works for regrips which are 2 apart
possible_start_regrips = {
grips: regrip
for grips, regrip in finger_regrips.items()
if grip_start == regrip.start
}
possible_end_regrips = {
grips: regrip
for grips, regrip in finger_regrips.items()
if grip_end == regrip.end
}
for start_regrip in possible_start_regrips.values():
for end_regrip in possible_end_regrips.values():
# if start grips ends at the beginning of end grip
if start_regrip.end == end_regrip.start:
finger_regrips[(start_regrip.start, end_regrip.end)] = (
Regrip(
finger=finger.name,
start=start_regrip.start,
end=end_regrip.end,
score=start_regrip.score + end_regrip.score,
)
)
return finger_regrips
def build_regrips_from_fingers(fingers: List[Finger]) -> List[Regrip]:
regrips = []
for finger in fingers:
finger_regrips = {}
for grip_set in finger.grips.values():
# reate a dict with distances of every two elements in a list
for i in range(len(grip_set)):
for j in range(len(grip_set)):
if i != j:
finger_regrips[(grip_set[i], grip_set[j])] = Regrip(
start=grip_set[i],
end=grip_set[j],
for i, grip_start in enumerate(grip_set):
for j, grip_end in enumerate(grip_set):
if grip_start != grip_end:
finger_regrips[(grip_start, grip_end)] = Regrip(
start=grip_start,
end=grip_end,
score=abs(j - i) * finger.default_score,
finger=finger.name,
)
for regrip in finger.regrips:
finger_regrips[(regrip.start, regrip.end)] = regrip
grips = {grip for grip_set in finger.grips.values() for grip in grip_set}
finger_regrips = build_missing_regrips(finger_regrips, finger, grips)
regrips.extend(finger_regrips.values())
return regrips
@ -182,7 +220,7 @@ def generate_finger_tricks(
# TODO: think about this
# don't count the first regrip
alg[0].finger_trick.score = 0
# alg[0].finger_trick.score = 0
return alg
@ -193,7 +231,11 @@ def build_pretty_string_from_finger_tricks_with_regrips(
for finger_trick_with_regrips in finger_tricks_with_regrips:
for regrip in finger_trick_with_regrips.regrips:
elems.append(f"regrip {regrip.finger} from {regrip.start} to {regrip.end}")
elems.append(finger_trick_with_regrips.finger_trick.name)
elems.append(
f"regrip {regrip.finger} from {regrip.start} to {regrip.end} ({regrip.score})"
)
elems.append(
f"{finger_trick_with_regrips.finger_trick.name} ({finger_trick_with_regrips.finger_trick.score})"
)
return elems

View File

@ -56,11 +56,16 @@ def create_eolrb_prune_table(prune_depth: int):
generator = lse_brute_force_generator(prune_depth)
pruned = 0
# TODO: for every solved state (pre auf), we can apply the generator's moves and save to prune table?
for alg in generator:
cube.reset()
cube.alg(" ".join(alg))
prune_table[cube.eolrb_hash()].append(reverse_algorithm(alg))
pruned += 1
if pruned % 1000 == 0:
print(pruned)
return prune_table

171
weighted_moves.yaml Normal file
View File

@ -0,0 +1,171 @@
fingers:
- name: index
default_score: 1
home_grips:
- BL
- LB
# TODO: change to grip_set
grips:
side:
- B
- BL
- LB
- LF
- FL
- F
top:
- UF
regrips:
- start: UF
end: BL
score: 3
# TODO: this doesn't need to be here
finger: index
- start: UF
end: LB
score: 3
# TODO: this doesn't need to be here
finger: index
- name: ring
default_score: 1
home_grips:
- B
- DB
grips:
slice:
- B
- DB
- DF
- F
regrips: []
- name: pinky
default_score: 1
home_grips:
- DB
- DF
grips:
slice:
- B
- DB
- DF
- F
- F floating
regrips:
- start: F floating
end: F
score: 2
# F floating is hard
# TODO: this doesn't need to be here
finger: pinky
finger_tricks:
- name: "U push"
move: "U"
grip_pre:
index: LB
grip_post:
index: B
grip_pre_blacklist: {}
score: 5
- name: "U flick"
move: "U"
grip_pre:
index: F
grip_post:
# TODO: rethink this parameter
index: LB
grip_pre_blacklist: {}
score: 4
- name: "U' push"
move: "U'"
grip_pre:
index: LF
grip_post:
index: F
grip_pre_blacklist: {}
score: 5
- name: "U' flick"
move: "U'"
grip_pre:
index: BL
grip_post:
index: LF
grip_pre_blacklist: {}
score: 3
- name: "U2' feido"
move: "U2"
grip_pre:
index: BL
grip_post:
index: F
grip_pre_blacklist: {}
score: 5
- name: "U2 double flick"
move: "U2"
grip_pre:
index: BL
grip_post:
index: LF
grip_pre_blacklist: {}
score: 6
- name: "U2' double flick"
move: "U2"
grip_pre:
index: F
grip_post:
index: BL
grip_pre_blacklist: {}
score: 9
- name: "U2 beido"
move: "U2"
grip_pre:
index: F
grip_post:
index: B
grip_pre_blacklist: {}
score: 5
- name: "M' ring flick"
move: "M'"
grip_pre:
ring: B
grip_post:
ring: DF
grip_pre_blacklist: {}
score: 3
- name: "M' pinky flick"
move: "M'"
# I can't do M' after finishing beido
grip_pre:
pinky: B
grip_post:
pinky: F floating
grip_pre_blacklist:
index:
- BL
- UF
score: 6
- name: "M push"
move: "M"
grip_pre:
pinky: F
grip_post:
pinky: DB
grip_pre_blacklist: {}
score: 5
- name: "M index push"
move: "M"
grip_pre:
index: B
grip_post:
index: UF
grip_pre_blacklist: {}
score: 6
- name: "M2 double flick"
move: "M2"
grip_pre:
pinky: B
ring: B
grip_post:
pinky: F floating
ring: DB
grip_pre_blacklist: {}
score: 7