code: def register_sparse():
      import sparse
  
      concatenate_lookup.register(sparse.COO, sparse.concatenate)
      tensordot_lookup.register(sparse.COO, sparse.tensordot)
      # Enforce dense ndarray for the numel result, since the sparse
      # array will wind up being dense with an unpredictable fill_value.
      # https://github.com/dask/dask/issues/7169
      numel_lookup.register(sparse.COO, _numel_ndarray)
      nannumel_lookup.register(sparse.COO, _nannumel_sparse)
  
imports: from __future__ import annotations
  import math
  import numpy
  from dask.array import chunk
  from dask.array.core import Array
  from dask.array.dispatch import concatenate_lookup, divide_lookup, einsum_lookup, empty_lookup, nannumel_lookup, numel_lookup, percentile_lookup, tensordot_lookup, to_cupy_dispatch, to_numpy_dispatch
  from dask.array.numpy_compat import divide
  from dask.array.numpy_compat import ma_divide
  from dask.array.percentile import _percentile
  from dask.backends import CreationDispatch, DaskBackendEntrypoint
label_desc: Use image node_id 6 for calling a global function with example usage: register_sparse() without return types