code: def check_classification_targets(y):
      """Ensure that target y is of a non-regression type.
  
      Only the following target types (as defined in type_of_target) are allowed:
          'binary', 'multiclass', 'multiclass-multioutput',
          'multilabel-indicator', 'multilabel-sequences'
  
      Parameters
      ----------
      y : array-like
      """
      y_type = type_of_target(y)
      if y_type not in [
          "binary",
          "multiclass",
          "multiclass-multioutput",
          "multilabel-indicator",
          "multilabel-sequences",
      ]:
          raise ValueError("Unknown label type: %r" % y_type)
  
imports: from __future__ import division
  from collections import Sequence
  from itertools import chain
  from scipy.sparse import issparse
  from scipy.sparse.base import spmatrix
  from scipy.sparse import dok_matrix
  from scipy.sparse import lil_matrix
  import numpy
  from ..externals.six import string_types
  from .validation import check_array
  from ..utils.fixes import bincount
  from ..utils.fixes import array_equal
label_desc: Use image node_id 6 for calling a global function with example usage: check_classification_targets(y) without return types