Week 2,exercise 1


NameError Traceback (most recent call last)
in
1 #(≈ 3 lines of code)
2 # YOUR CODE STARTS HERE
----> 3 m_train = train_set_x_orig.shape[0]
4 m_test = test_set_x_orig.shape[0]
5 num_px = train_set_x_orig.shape[1]

NameError: name ‘train_set_x_orig’ is not defined

everything is correct but still, it is showing this error

Welcome to the community.

Please make sure that you run the following cell beforehand.

# Loading the data (cat/non-cat)
train_set_x_orig, train_set_y, test_set_x_orig, test_set_y, classes = load_dataset()

You see this cell slightly above your current cell.

1 Like

Thanks alot Nobu_Asai! Am a newbie that’s why i got that error