Skip to content

Commit

Permalink
Fix simple typo: symetry -> symmetry (#332)
Browse files Browse the repository at this point in the history
  • Loading branch information
timgates42 committed Apr 12, 2020
1 parent fb10612 commit e1286cf
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/test_similarities.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def test_cosine_sim():

sim = sims.cosine(n_x, yr, min_support=1)

# check symetry and bounds (as ratings are > 0, cosine sim must be >= 0)
# check symmetry and bounds (as ratings are > 0, cosine sim must be >= 0)
for xi in range(n_x):
assert sim[xi, xi] == 1
for xj in range(n_x):
Expand Down Expand Up @@ -81,7 +81,7 @@ def test_msd_sim():

sim = sims.msd(n_x, yr, min_support=1)

# check symetry and bounds. MSD sim must be in [0, 1]
# check symmetry and bounds. MSD sim must be in [0, 1]
for xi in range(n_x):
assert sim[xi, xi] == 1
for xj in range(n_x):
Expand Down Expand Up @@ -120,7 +120,7 @@ def test_pearson_sim():
random.shuffle(ratings)

sim = sims.pearson(n_x, yr, min_support=1)
# check symetry and bounds. -1 <= pearson coeff <= 1
# check symmetry and bounds. -1 <= pearson coeff <= 1
for xi in range(n_x):
assert sim[xi, xi] == 1
for xj in range(n_x):
Expand Down Expand Up @@ -182,7 +182,7 @@ def test_pearson_baseline_sim():
x_biases = np.random.normal(0, 1, n_x) # fake
y_biases = np.random.normal(0, 1, 5) # fake (there are 5 ys)
sim = sims.pearson_baseline(n_x, yr, 1, global_mean, x_biases, y_biases)
# check symetry and bounds. -1 <= pearson coeff <= 1
# check symmetry and bounds. -1 <= pearson coeff <= 1
for xi in range(n_x):
assert sim[xi, xi] == 1
for xj in range(n_x):
Expand Down

0 comments on commit e1286cf

Please sign in to comment.