使用tensorflow自定义loss函数定义python函数wrapper类
文章目录定义python函数wrapper类定义python函数 def my_huber_loss(y_true, y_pred): error = y_true - y_pred is_small_error = tf.abs(error) <= threshold small_error_loss = tf.square(error) / 2 big_error_loss = threshold * (tf.abs