ValueError: Found array with dim 3. Estimator expected <= 2

Hi, I keep getting this error while executing the Multiclass Classification in FFN.

Kindly Help.

Notebook Link :

You are supposed to pass a 2D input to OneHotEncoder module. See the example here:

You can probably try removing np.expand_dims(), which adds an extra dimension to the 2D input and makes it 3D.