I have set my numpy random seed to 0. I am training on colab and using keras. I didn't change anything. I just re-ran my cell and the val_absolute_error changed.
Code:
np.random.seed(0)
regressor = Sequential()
regressor.add(Dense(10, input_dim=1, activation='tanh'))
regressor.add(Dense(20, input_dim=1, activation='relu'))
regressor.add(Dense(15, input_dim=1, activation='tanh'))
regressor.add(Dense(1))
regressor.compile(optimizer='adam', loss='mean_absolute_error', metrics=['mae'])
model = regressor.fit(X_train, y_train, epochs=450, batch_size=10, validation_data=(X_val, y_val), verbose=1)
print(regressor.evaluate(X_test, y_test)) --> This is the error on the test set
Please note that I made a mistake in the screenshot, it is the error in test set not val. set
train_test_split
from scikit-learn the split will be randomised. $\endgroup$