Skip to content

Commit

Permalink
convert pandas dataset to numpy array so that np.reshape can work on it
Browse files Browse the repository at this point in the history
  • Loading branch information
yuval committed Mar 10, 2021
1 parent f6fdfaa commit 3176809
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion py/htm/examples/mnist.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def load_ds(name, num_test, shape=None):
X = data['data']
if shape is not None:
new_shape = shape.insert(0, sz)
X = np.reshape(X, shape)
X = np.reshape(X.to_numpy(), shape)

y = data['target'].astype(np.int32)
# split to train/test data
Expand Down

0 comments on commit 3176809

Please sign in to comment.