Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Plot of the Pseudo-Huber loss
- delta = tf.constant(0.24)
- temp_ph = tf.multiply(tf.square(delta),tf.sqrt(1. + tf.square((Y_truth - Y_pred) / delta)) - 1. )
- pseudo_h_vals = sess.run(temp_ph)
- #ploting the predicted values against the L2 loss
- Y_array = sess.run(Y_pred)
- plt.plot(Y_array, pseudo_h_vals, 'g-' )
- plt.title('Pseudo Huber loss')
- plt.xlabel('$Y_{pred}$', fontsize=15)
- plt.ylabel('$Y_{true}$', fontsize=15)
Add Comment
Please, Sign In to add comment