import numpy as np import tensorflow as tf y_pred = np.array([[1], [2], [3]],dtype=np.float32) y_real = np.array([[1], [1], [1]]) bias = np.array([1,2,3,4],dtype=np.float32) with tf.Session() as sess: sess.run(tf.global_variables_initializer()) Input…