week2-Python_Basics_with_Numpy-7.softmax_test fail

Hi, I’m getting below error while running exercise 7. I double checked my 3 line code and I’m using x_exp in x_sum etc. Anyone have similar issue; please help.

OUTPUT–
softmax(x) = [[9.80897665e-01 8.94462891e-04 1.79657674e-02 1.21052389e-04
1.21052389e-04]
[8.78679856e-01 1.18916387e-01 8.01252314e-04 8.01252314e-04
8.01252314e-04]]

NameError Traceback (most recent call last)
in
3 print("softmax(x) = " + str(softmax(t_x)))
4
----> 5 softmax_test(softmax)

NameError: name ‘softmax_test’ is not defined

The error means that softmax_test is not defined, is it somewhere in a cell upwards that you forgot to run?

1 Like

Thanks gent.spah, your response helped solve my problem. I refreshed page and ran all the cells from beginning and it worked. Silly mistake from my end.

1 Like