from tensorflow.python.ops import math_ops

      # "accuracy/threshold_0.500000_mean" metric for binary classification.
      metrics = {("accuracy", "classes"): metric_ops.streaming_accuracy}

    predictions = math_ops.sigmoid(logits)
    labels_float = math_ops.to_float(labels)

