code: def _check_binary_probabilistic_predictions(y_true, y_prob):
      """Check that y_true is binary and y_prob contains valid probabilities"""
      check_consistent_length(y_true, y_prob)
  
      labels = np.unique(y_true)
  
      if len(labels) > 2:
          raise ValueError(
              "Only binary classification is supported. "
              "Provided labels %s." % labels
          )
  
      if y_prob.max() > 1:
          raise ValueError("y_prob contains values greater than 1.")
  
      if y_prob.min() < 0:
          raise ValueError("y_prob contains values less than 0.")
  
      return label_binarize(y_true, labels)[:, 0]
  
imports: from __future__ import division
  import warnings
  import numpy
  from scipy.sparse import coo_matrix
  from scipy.sparse import csr_matrix
  from ..preprocessing import LabelBinarizer, label_binarize
  from ..preprocessing import LabelEncoder
  from ..utils import assert_all_finite
  from ..utils import check_array
  from ..utils import check_consistent_length
  from ..utils import column_or_1d
  from ..utils.multiclass import unique_labels
  from ..utils.multiclass import type_of_target
  from ..utils.validation import _num_samples
  from ..utils.sparsefuncs import count_nonzero
  from ..utils.fixes import bincount
  from ..exceptions import UndefinedMetricWarning
label_desc: Use image node_id 19 for calling a global function with example usage: _check_binary_probabilistic_predictions(y_true, y_prob) and returns: label_binarize