code: def to_scipy(index, value, m, n):
      assert not index.is_cuda and not value.is_cuda
      (row, col), data = index.detach(), value.detach()
      return scipy.sparse.coo_matrix((data, (row, col)), (m, n))
  
imports: import numpy
  import scipy.sparse
  import torch
  from torch import from_numpy
label_desc: Use image node_id 3 for calling a global function with example usage: to_scipy(index, value, m, n) and returns: scipy