Explorar el Código

Fixing a bug in the scoring logic, turns out I need to relearn python

Kirk Trombley hace 5 años
padre
commit
51d736d824
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      server/lib.py

+ 1 - 1
server/lib.py

@@ -58,5 +58,5 @@ def score(target, guess):
         return 0, dist_km
 
     # Gaussian, with some manual tuning to get good fall off
-    exponent = -((dist_km - min_dist_km) ^ 2) / exp_denom
+    exponent = -((dist_km - min_dist_km) ** 2) / exp_denom
     return int(perfect_score * math.exp(exponent)), dist_km