class_docstr: This class simply exists to hold the methods necessary for fancy indexing.
class_docstr_tok: ["This","class","simply","exists","to","hold","the","methods","necessary","for","fancy","indexing","."]
code: def _check_boolean(self, row, col):
      from .base import isspmatrix  # ew...
  
      # Supporting sparse boolean indexing with both row and col does
      # not work because spmatrix.ndim is always 2.
      if isspmatrix(row) or isspmatrix(col):
          raise IndexError(
              "Indexing with sparse matrices is not supported "
              "except boolean indexing where matrix and index "
              "are equal shapes."
          )
      if isinstance(row, np.ndarray) and row.dtype.kind == "b":
          row = self._boolean_index_to_array(row)
      if isinstance(col, np.ndarray) and col.dtype.kind == "b":
          col = self._boolean_index_to_array(col)
      return row, col
  
imports: from __future__ import division, print_function, absolute_import
  import operator
  import warnings
  import numpy
  from scipy._lib._version import NumpyVersion
label_desc: Use image node_id 4 for calling the IndexMixin obj's underlying member method code with example usage: obj._check_boolean(row, col) and returns: row,  col