code: def _check_y(y):
    
    if not isinstance(y, np.ndarray):
      raise TypeError("y must be numpy array. Typically y contains "
                      "the entire test set labels. Got " + str(y) + " of type " + str(type(y)))
docs: Makes sure a `y` argument is a vliad numpy dataset.