code: def abs_error(predictions, labels, weights_fn=None):
    
    del weights_fn  # Unused
    targets = tf.squeeze(labels, axis=[2, 3])
    batch_abs_error = tf.abs(predictions - targets)
    den = tf.ones(tf.shape(batch_abs_error), dtype=tf.float32)
    return (batch_abs_error, den)
docs: Computes mean(abs(preds-target)).