code: def auc(y_true, y_pred, round=True):
      
      y_true, y_pred = _mask_value_nan(y_true, y_pred)
  
      if round:
          y_true = y_true.round()
      if len(y_true) == 0 or len(np.unique(y_true)) < 2:
          return np.nan
      return skm.roc_auc_score(y_true, y_pred)
docs: Area under the ROC curve