code: def sp_div(
      A: SparseMatrix, B: Union[SparseMatrix, Scalar]
  ) -> SparseMatrix:
      """Elementwise division
  
      If :attr:`B` is a sparse matrix, both :attr:`A` and :attr:`B` must have the
      same sparsity. And the returned matrix has the same order of non-zero
      entries as :attr:`A`.
  
      Parameters
      ----------
      A : SparseMatrix
          First operand
      B : SparseMatrix or Scalar
          Second operand
  
      Returns
      -------
      SparseMatrix
          Result of A / B
  
      Examples
      --------
      >>> indices = torch.tensor([[1, 0, 2], [0, 3, 2]])
      >>> val = torch.tensor([1, 2, 3])
      >>> A = dglsp.spmatrix(indices, val, shape=(3, 4))
      >>> A / 2
      SparseMatrix(indices=tensor([[1, 0, 2],
                                   [0, 3, 2]]),
                   values=tensor([0.5000, 1.0000, 1.5000]),
                   shape=(3, 4), nnz=3)
      """
      if is_scalar(B):
          return val_like(A, A.val / B)
      return spsp_div(A, B)
  
file_path: dgl/python/dgl/sparse/elementwise_op_sp.py
imports: from typing import Union
  import torch
  from .sparse_matrix import SparseMatrix, val_like
  from .utils import is_scalar, Scalar
label_desc: Use image node_id 7 for calling a global function with example usage: sp_div(A, B) and returns: spsp_div, val_like