Benjamin Bossan commited on
Commit
dffd3b5
1 Parent(s): e04e7d0

Bugfix (possibly?): make spiral data c contiguous

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -97,7 +97,7 @@ def get_spiral(n_clusters):
97
  y = t * np.sin(t)
98
  X = np.concatenate((x, y))
99
  X += 0.7 * np.random.randn(2, N_SAMPLES)
100
- X = X.T
101
 
102
  labels = np.zeros(N_SAMPLES, dtype=int)
103
  return normalize(X), labels
 
97
  y = t * np.sin(t)
98
  X = np.concatenate((x, y))
99
  X += 0.7 * np.random.randn(2, N_SAMPLES)
100
+ X = np.ascontiguousarray(X.T)
101
 
102
  labels = np.zeros(N_SAMPLES, dtype=int)
103
  return normalize(X), labels