A question of random set in NN

tf.random.set_seed(1)
cost_fn = tf.keras.losses.MeanSquaredError()
opt = keras.optimizers.Adam(learning_rate=0.01)
model.compile(optimizer=opt,
loss=cost_fn)

tf.random.set_seed(1)
model.fit([user_train[:, u_s:], item_train[:, i_s:]], y_train, epochs=30)

for this code(from Practice lab: Deep Learning for Content-Based Filtering), what is the purpose of “tf.random.set_seed(1)”

Any help would be appreciated!

The purpose of using the seed is to be able to reproduce the same random set every time for testing and evaluation purposes.