# HG changeset patch # User Arne Babenhauserheide # Date 1295892406 -3600 # Mon Jan 24 19:06:46 2011 +0100 # Branch gameboard-g13 # Node ID 7c7e742b8de927cde354337cf7f391cd35fda3bb # Parent c2c0f81c3b293bc4d0138b2ad104dd4511bd54b8 doubled cost for finger repeats on the pinky. diff --git a/config.py b/config.py --- a/config.py +++ b/config.py @@ -15,6 +15,7 @@ WEIGHT_FINGER_REPEATS = 512 #: Cost of a finger repeat. Gets additional +1 from the row change on the same finger. WEIGHT_FINGER_REPEATS_INDEXFINGER_MULTIPLIER = 0.5 #: Cost of a finger repeat on rhe indexfinger (hurts less). Warning: Any value different from 1 means that the percentage of finger repeats reported by check_neo.py will be incorrect. +WEIGHT_FINGER_REPEATS_PINKY_MULTIPLIER = 2 #: Cost of a finger repeat on rhe pinky (hurts much more on the one-hand gameboard). Warning: Any value different from 1 means that the percentage of finger repeats reported by check_neo.py will be incorrect. WEIGHT_FINGER_REPEATS_CRITICAL_FRACTION = 0.0005 #: The cost of finger repeats with a fraction of the bigrams higher than this is increased sharply, relative to the amount by which they exceed the fraction. Value guessed from experience from effchen (adnw ln disturbs writing, below that does not). 0.05% is about once per DinA4-page (30 lines, 60 letters). There should be no single finger repetition which appears once per DinA4 page, because that will stick to ones mind as a cludge. WEIGHT_FINGER_REPEATS_CRITICAL_FRACTION_MULTIPLIER = 5 #: The amount of usage higher than the critical fraction is multiplied by this multiplier. Warning: Any value different from 1 means that the percentage of finger repeats reported by check_neo.py will be incorrect. diff --git a/layout_cost.py b/layout_cost.py --- a/layout_cost.py +++ b/layout_cost.py @@ -124,8 +124,11 @@ if finger1 and finger2 and finger1 == finger2: # reduce the cost for finger repetitions of the index finger (it’s very flexible) - if finger1.startswith("Zeige") or finger2.startswith("Zeige"): + if finger1.startswith("Zeige"): number *= WEIGHT_FINGER_REPEATS_INDEXFINGER_MULTIPLIER + # reduce the cost for finger repetitions of the index finger (it’s very flexible) + elif finger1.startswith("Klein"): + number *= WEIGHT_FINGER_REPEATS_PINKY_MULTIPLIER # increase the cost abovet the critical point if number > critical_point and number_of_keystrokes > 20: # >20 to avoid kicking in for single bigram checks. #print(pair, number, number/number_of_keystrokes, WEIGHT_FINGER_REPEATS_CRITICAL_FRACTION, (number - critical_point)*WEIGHT_FINGER_REPEATS_CRITICAL_FRACTION_MULTIPLIER)