here why we are not vectorizing ytest and ytrain?why we are converting them to float…whereas xtest and xtrain are in intigers?
Didnt understand the need of conversion to float
See, our model predicts a float value representing the ‘confidence’ (just like in Logistic Regression) when we pass an x_data into it. To compute loss we would have to take the difference between the actual values (which are stored in the y_train) and the values predicted by our model, thus both of them must be in the same data type, i.e., float.
It’s a case of binary classification, we do not need to vectorise them because our network is predicting one single value also which is being compared to the actual value.
1 Like