def root_mean_square_error(y_real, y_pred):
 (y_real, y_pred) = check_arrays(y_real, y_pred)
 return np.sqrt((np.sum(((y_pred - y_real) ** 2)) / y_real.shape[0]))

def root_mean_square_error ( y_real , y_pred ) : ( y_real , y_pred ) = check_arrays ( y_real , y_pred ) return np . sqrt ( ( np . sum ( ( ( y_pred - y_real ) ** 2 ) ) / y_real . shape [ 0 ] ) )
it computes the root mean squared difference between predicted and actual ratings for users .