docstr: Returns number of non-zero entries.
  
  .. note::
     This method counts the actual number of non-zero entories, which
     does not include explicit zero entries.
     Instead ``nnz`` returns the number of entries including explicit
     zeros.
  
  Returns:
      Number of non-zero entries.
docstr_tok: ["Returns","number","of","non-zero","entries",".","..","note",":",":","This","method","counts","the","actual","number","of","non-zero","entories",",","which","does","not","include","explicit","zero","entries",".","Instead","``","nnz","``","returns","the","number","of","entries","including","explicit","zeros",".","Returns",":","Number","of","non-zero","entries","."]
code: def count_nonzero(self):
      """Returns number of non-zero entries.
  
      .. note::
         This method counts the actual number of non-zero entories, which
         does not include explicit zero entries.
         Instead ``nnz`` returns the number of entries including explicit
         zeros.
  
      Returns:
          Number of non-zero entries.
  
      """
      return cupy.count_nonzero(self.data)
  
imports: import cupy
  import numpy
  from cupy._core import internal
  from cupy import _util
  from cupyx.scipy.sparse import _base
  from cupyx.scipy.sparse import _coo
  from cupyx.scipy.sparse import _sputils
label_desc: Use image node_id 9 for calling the _data_matrix obj's underlying member method code with example usage: obj.count_nonzero() and returns: cupy