Skip to content

Commit 42e27f3

Browse files
authored
Merge pull request #147 from jeffin07/softmax
softmax bug fix
2 parents 6e5af2a + c278a72 commit 42e27f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

neuralpy/layers/activation_functions/softmax.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def __init__(self, dim=None, name=None):
2929
"""
3030
super().__init__(_Softmax, "Softmax", layer_name=name)
3131

32-
if not isinstance(dim, int):
32+
if dim is not None and not isinstance(dim, int):
3333
raise ValueError("Please provide a valid dim")
3434

3535
self.__dim = dim

0 commit comments

Comments
 (0)