Skip to content

Commit

Permalink
Merge branch 'latest_numpy_support' into github_ci
Browse files Browse the repository at this point in the history
  • Loading branch information
wkcn committed Jun 18, 2024
2 parents 4f0d2d1 + 92192bf commit 380a8a2
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 7 deletions.
3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +0,0 @@
[submodule "thirdparty/numpy-groupies"]
path = thirdparty/numpy-groupies
url = https://github.com/ml31415/numpy-groupies
2 changes: 1 addition & 1 deletion examples/mnist_kaggle.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def print_info():

n = len(data)
X = data[:, 1:]
labels = data[:, 0].astype(np.int)
labels = data[:, 0].astype(np.int32)
# one-hot
#Y = np.eye(10)[labels.ravel()]
print ("Read OK", n)
Expand Down
2 changes: 1 addition & 1 deletion examples/mnist_train.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

n = len(data)
X = data[:, 1:]
labels = data[:, 0].astype(np.int)
labels = data[:, 0].astype(np.int32)
# one-hot
#Y = np.eye(10)[labels.ravel()]
print ("Read OK", n)
Expand Down
2 changes: 1 addition & 1 deletion mobula/layers/Eltwise.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def forward(self):
elif self.op == Eltwise.PROD:
for i in range(len(self.X)):
x = self.X[i]
x[x == 0] = 1e-100
x[x == 0] = 1e-10
self.Y = np.prod(self.X, 0) * np.prod(self.coeffs)
else:
# self.op == Eltwise.MAX
Expand Down
1 change: 0 additions & 1 deletion thirdparty/numpy-groupies
Submodule numpy-groupies deleted from dffc66

0 comments on commit 380a8a2

Please sign in to comment.